1.

Solve : Stretched Background?

Answer»

Ive been working on a website and Ive been trying to stretch a BACKGROUND. I have a code, however, instead of STRETCHING the whole page, it only stretches it at the top of the document above all the text. Heres the code:


/* pushes the page to the FULL capacity of the viewing area */
html {height:100%;}
body {height:100%; margin:0; padding:0;}
/* prepares the background image to full capacity of the viewing area */
#bg {position:fixed; top:0; left:0; width:100%; height:100%;}
/* places the content ontop of the background image */
#content {position:relative; z-index:1;}






Enter a ton of text or whatever here.







Can someone help me with this code or give me a different ONE.

--ThanksIs this the whole script?
try taking the second "#bg" content and merge it with the first. like this:
Code: [Select]#bg {position:fixed; top:0; left:0; width:100%; height:100%; position:ABSOLUTE; z-index:-1;}


Discussion

No Comment Found