HTML catagorizes elements into specific categories. The two main types of HTML element categories are:
Block - Include a line break before and after the element.
Inline - Included with the text as part of a line.
See the section called "HTML Element Categories" for a list of block and inline elements with short descriptions.
In HTML there are specific rules with regard to what elements a specific element may contain. For example some elements may only be contained in the HEAD header element. The paragraph element may not contain block elements. The table below lists elements and what they may contain:
Name
Contained Elements
A
inline elements except A
ABBR
inline elements
ACRONYM
inline elements
ADDRESS
inline elements
APPLET
PARAM, inline elements block elements
AREA
none
B
inline elements
BASE
none
BASEFONT
none
BDO
inline elements
BIG
inline elements
BLOCKQUOTE
block elements, SCRIPT
BODY
inline elements, block elements
BR
none
BUTTON
inline elements excluding A, BUTTON, INPUT, LABEL, IFRAME, SELECT, and TEXTAREA
CENTER
inline elements, block elements
CITE
inline elements
CODE
inline elements
DD
inline elements
DEL
inline elements, block elements
DFN
inline elements
DIR
LI excluding block elements
DIV
inline elements, block elements
DL
DD, DT
DT
inline elements, block elements
EM
inline elements
FIELDSET
inline elements, block elements, LEGEND
FONT
inline elements
FORM
block elements excluding FORM
FRAME
none
FRAMESET
FRAMESET, FRAME, NOFRAMES
H1-H6
inline elements
HEAD
BASE, ISINDEX, LINK, META, OBJECT, SCRIPT, STYLE, TITLE
HR
none
I
inline elements
IFRAME
inline elements, block elements
IMG
none
INPUT
inline elements, block elements excluding BUTTON
INS
inline elements, block elements
ISINDEX
none
HTML
HEAD, BODY, FRAMESET
KBD
inline elements
LABEL
inline elements excluding LABEL
LEGEND
inline elements
LI
inline elements, block elements (MENU and DIR list items exclude block elements)