View Full Version : Split background with CSS
VatsaL
12-25-2006, 04:54 PM
Hello all,
Any idea how I can attain a horizontal split background with space in middle, without any images like this?
http://www.b3ta.cr3ation.co.uk/data/gif/bg.gif
mwinter
12-26-2006, 03:15 PM
Any idea how I can attain a horizontal split background with space in middle, without any images like this?
That depends. Is this space directly related to content in the document? If so, a container for that content can have a white background, whilst the body element has the blue-grey background. If not, then an image is the best solution. A 162-byte PNG (http://mwinter.webhop.info/dd/vatsal/background.png) would do the trick, using the declaration
background: #ebeff2 url(background.png) 0% 0% repeat-x;
applied to the body element.
Mike
djr33
12-26-2006, 04:16 PM
Yeah, if you can use two seperate elements each with one color, then that's easy and would work well. Two divs, for example, or, as mike said, something and the body.
VatsaL
12-26-2006, 08:02 PM
Thanks, that worked perfect!
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.