UBB.Dev
Posted By: Gregori Ad bgproperties to body tag - 02/14/2004 3:06 AM
I want to add bgproperties="fixed" to the body tag, so that my bakground image don´t scroll.

But where do I add it? I can´t find the proper file for this!

Anyone?
Posted By: JustDave Re: Ad bgproperties to body tag - 02/14/2004 3:46 AM
In your .css files, under the body style.

Example:

body {
color: #000000;
font-family: Tahoma, Trembuchet MS Verdana, Arial, Helvetica, sans-serif;
font-size: 14px;
background: #FFFFFF url(some.gif) no-repeat fixed left top;
padding-top: 20px;
padding-right: 20px;
padding-bottom: 20px;
padding-left: 20px;
}


Hope that helps.
Posted By: Gregori Re: Ad bgproperties to body tag - 02/14/2004 11:25 AM
It sounded good, but this only seem to work in Explorer.
Posted By: J.C. Re: Ad bgproperties to body tag - 02/14/2004 3:06 PM
The tag background by itself is not sufficient, according to w3c.org.

Example:
BODY {
background: red url("pendant.gif");
background-repeat: repeat-y;
background-attachment: fixed;
}
Posted By: Gregori Re: Ad bgproperties to body tag - 02/15/2004 11:42 AM
That did the trick!

Thanks!
Posted By: JustDave Re: Ad bgproperties to body tag - 02/16/2004 6:07 PM
I think my example needed quotes around the "url" so it should work once them are in.
© UBB.Developers