Welcome to WebmasterWorld Guest from 54.82.99.169

Forum Moderators: open

Message Too Old, No Replies

css-ing the html element?

     
5:32 pm on Mar 16, 2010 (gmt 0)

Junior Member

10+ Year Member

joined:Jan 18, 2008
posts:100
votes: 0


is there anything bad about giving the html element a background-image?

When giving the body a background-image there are issues because the body does not cover the whole viewport at times. i've found a workaround that gives the html element a background-image and a min-height of 100%. It works in IE6-8, FF, Chrome, Safari, and works in Opera if you remove the min-height.

does anyone see any problems with this?

i've run into this problem playing around with the new -moz-linear-gradient for FF 3.6.

You'll see the problem if you create a page where the body is shorter than the viewport and you give the body element a linear gradient (may happen with radial gradients too)
6:43 pm on Mar 16, 2010 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:May 23, 2005
posts:742
votes: 0


I looked into this last year and don't recall there being any issues.
7:32 pm on Mar 16, 2010 (gmt 0)

Junior Member

10+ Year Member

joined:Jan 18, 2008
posts:100
votes: 0


excellent, thanks!