Monday, September 13, 2010

The body section

The body element is used to define the body of a web page, and it contains the document’s
content. No document content should ever be placed outside of the body element.
Sorry for the italic type, but this is something I see on a regular basis, so I wanted to nip
that one in the bud.
Although the body element has a number of possible attributes that can be included in its
start tag, mostly for defining link state color and backgrounds, these should be avoided.
This is because such things should be dealt with using CSS, which enables you to define
values on a site-wide basis, rather than having to do so for each individual page. The body
element attributes include the likes of alink, link, and vlink for defining link colors; text
for defining the default text color; and background and bgcolor for defining a background
pattern and color. There are also a number of proprietary attributes that were intended to
set padding around web page content, which aren’t worth mentioning further. In this next
section, we’ll look at the contemporary way of setting content margins and padding,
default font and color, and web page backgrounds.

No comments:

Post a Comment