Root Element Properties
For HTML, but not for XHTML, the CSS2.1 specification recommends that we specify
the document background for the body element, rather
than for the html element. If the computed value of the
background property for the html element is transparent
(the initial value), any background properties specified for the
body element will be applied to the canvas. This isn’t the case for XHTML.
The CSS2.1 specification also says that an overflow
property declared for the body or
html elements may be applied to the viewport, but only
for HTML documents. In reality, though, browsers apply this property to
the viewport for XHTML documents too.
Previous / Next page
- Previous
- Next
User-contributed notes
There are no comments yet.
Add a note
To post a note on this topic, please log in with your SitePoint username and password. If you don't have an account yet, you can create a new account for free.