SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru Marc's Avatar
    Join Date
    Nov 2000
    Location
    New York
    Posts
    765
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Use a background image AND a background tile?

    I'm a newbie to css-p, and here's my question:

    I have a block element (<div>) that I'm positioning absolutely. I want it to have a background of a certain picture, but I don't want that background picture to repeat. So I specified:

    background-repeat: no-repeat;

    Now that's good and dandy, but what I want to know now is how to use another background image to be tiled vertically everywhere else that the non-repeating background image doesn't fill up.

    Does this make any sense?
    Marc Gugliuzza
    marc.gugliuzza.com



  2. #2
    SitePoint Enthusiast JohnShaft's Avatar
    Join Date
    Oct 2002
    Location
    England
    Posts
    48
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well if you put the non repeating image in one div, on top of the image for the background that didn repeat you would get that effect on the screen.

    If for some reason you need one non repeating image in the div AND a repeating image where it isn't in the div then I certainly don't know of a way of doing it.

    With most applications of this effect I would think that using the first way would be fine, to go the second route just seems a pain, and unnecessary.
    Of course it depends on the application. If you really need way #2 good luck 'cos it's beyond me.
    HorrorExpress.com - all the latest Horror Movie Reviews and News


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •