inherit
133493
0
Jul 7, 2010 15:48:57 GMT -8
++ Misery Bless
245
November 2008
meowmeowkat
|
Post by ++ Misery Bless on Sept 5, 2009 23:24:55 GMT -8
<style type="text/css"> body{ background: white; background-repeat:repeat-x; background-repeat:repeat-y; } </style>
Currently, that code makes the background while, but what if I wanted to have 2 body backgrounds? What would I do then?
Note: I know, only one background will appear at a time, but how would I be able to create two?
|
|
inherit
100824
0
May 13, 2012 5:37:49 GMT -8
Michael
14,585
March 2007
wrighty
|
Post by Michael on Sept 6, 2009 6:43:00 GMT -8
O.o Could you perhaps elaborate on what you mean - you say you want 2, but then you say that you know only one will appear!
|
|
inherit
130228
0
Jul 11, 2024 19:19:59 GMT -8
Charles Stover
1,731
August 2008
gamechief
|
Post by Charles Stover on Sept 6, 2009 8:16:24 GMT -8
Firstly, background-repeat : repeat-x; background-repeat : repeat-y;
The repeat-y will override the repeat-x. What you're looking for is background-repeat : repeat;
As for multiple backgrounds, it won't be until CSS3 that one element can support multiple background images. Until then, you'll need multiple elements.
body { background : url("etc.jpg"); } div#wrapper { background : url("etc2.jpg"); }
<body><div id="wrapper"> Content here. </div></body>
|
|
inherit
71337
0
Sept 16, 2021 16:47:32 GMT -8
Zath
aka Salma or Ardbeg :
2,607
February 2006
sexysalma
|
Post by Zath on Sept 8, 2009 14:59:55 GMT -8
Firstly, background-repeat : repeat-x; background-repeat : repeat-y; The repeat-y will override the repeat-x. What you're looking for is background-repeat : repeat; As for multiple backgrounds, it won't be until CSS3 that one element can support multiple background images. Until then, you'll need multiple elements. body { background : url("etc.jpg"); } div#wrapper { background : url("etc2.jpg"); } <body><div id="wrapper"> Content here. </div></body> You can simplify that Charles. Do away with the wrapper div and give the body tag it's own ID. <body id="daytime"> content </body> <body id="nightime"> content </body> Then use CSS with #daytime {background-color:#FFFFFF;} #nightime {background-color:#000000;}
|
|
inherit
130228
0
Jul 11, 2024 19:19:59 GMT -8
Charles Stover
1,731
August 2008
gamechief
|
Post by Charles Stover on Sept 10, 2009 13:08:11 GMT -8
But that doesn't do what mine does. =/
Mine displays two backgrounds at the same time (which is what I assumed Misery Bless wanted).
|
|
inherit
71337
0
Sept 16, 2021 16:47:32 GMT -8
Zath
aka Salma or Ardbeg :
2,607
February 2006
sexysalma
|
Post by Zath on Sept 10, 2009 16:58:17 GMT -8
But that doesn't do what mine does. =/ Mine displays two backgrounds at the same time (which is what I assumed Misery Bless wanted). Sorry, I misread the OP
|
|