Cross-Section Categories Filter

C  Programming Basics  PHP (Hypertext Preprocessor)  Welcome to EducationForge  Articles of Use  Internet  More Topics  Management  HTML (Hypertext Markup Language)  Computer Basics  



The Document Body

The document body is the meat of the matter; it's where you put the contents of your document. The < body > tag delimits the document body.

The < body > Tag

Within HTML 4 and XHTML, the < body > tag has a number of attributes that control the color and background of your document. Various browsers have extended the tag to give even greater control over your document's appearance.

< body >

Function

Defines the document body

Attributes

alink, background, bgcolor, bgproperties, class, dir, id, lang, leftmargin , link, onBlur, onClick, onDblClick, onFocus, onKeyDown, onKeyPress, onKeyUp, onLoad, onMouseDown, onMouseMove, onMouseOut, onMouseOver, onMouseUp, onUnload, style, text, title, topmargin, vlink, onKeyDown

End tag

< /body >; may be omitted in HTML

Contains

body_content

Used in

html_tag

Anything between the < body > tag and its ending counterpart, < /body >, is called body content. The simplest document might have only a sequence of text paragraphs within the < body > tag. More complex documents might include heavily formatted text, graphical figures, tables, and a variety of special effects.

Since the position of the < body > and < /body > tags can be inferred by the browser, they can safely be omitted from an HTML, but not an XHTML, document. Like the < html > and < head > tags, we recommend that you include the < body > tags in your HTML documents, too, to make them more easily readable and maintainable.

The various attributes for the < body > tag can be loosely grouped into three sets: those that give you some control over the document's appearance, those that associate programmable functions with the document itself, and those that label and identify the body for later reference.

Frames

The HTML and XHTML standards define a special type of document in which you replace the < body > tag with one or more < frameset > tags. This so-called frame document divides the display window into one or more independent windows, each displaying a different document.



Socialize the Article

Share/Bookmark

Digg  Technorati  del.icio.us  Stumbleupon  Reddit  Blinklist  Furl  Spurl  Yahoo  Simpy

Article Stats

Current Grade of Article: C
This article has been rated 57 times to achieve this grade.

Grade the article: