HOME
MAIN
NEXT
PREV
HTML List Elements Summary
HOME
MAIN
NEXT
DL Element: Description/Glossary List
Usage:
<DL>...</DL>
Can Contain: DT, DD
Can Be Inside: BLOCKQUOTE, BODY, CENTER, DD, DIV, FORM, LI,
TD,
TH
Attributes: COMPACT
DL defines glossary-like lists, and can only contains two elements: DT
(description term) and DD (the description).
- Attributes:
- COMPACT (optional): the list should be rendered in a physical compact way. This
tends to close up text and reduce spacing between items. It is used in
Netscape Navigator, and it is not understood by most other commercial
browsers
TOP
- Example 1: DL with DT and DD elements
<DL>
<DT>Descriptive term with out descriptive
data <BR><BR>
<DT>First descriptive term
<DD>First
descriptive data
<DT>Last
descriptive term
<DD>Last
descriptive term
</DL>
- Descriptive term with out descriptive data
- First descriptive term
- First descriptive data
- Last descriptive term
- Last descriptive term
TOP
- Example 2: DL with COMPACT attribute
<DL COMPACT>
<DT>Descriptive term with out descriptive
data <BR><BR>
<DT>First descriptive term
<DD>First
descriptive data
<DT>Last
descriptive term
<DD>Last
descriptive term
</DL>
- Descriptive term with out descriptive data
- First descriptive term
- First descriptive data
- Last descriptive term
- Last descriptive term
HOME
MAIN
NEXT
PREV
DT Element: Description Term in a Glossary List
Usage:
<DT>...(</DT>)
Can Contain: characters, character highlighting,
A, APPLET, BR, IMG,
BASEFONT, MAP, SCRIPT, INPUT, SELECT, TEXTAREA
Can Be Inside: DL
Attributes: none
DT contains the term part of a glossary or description list entry. The
contents of a DT element should be short: typically, a few words, and certainly
shorter than a line.
HOME
MAIN
NEXT
PREV
DD Element: Description in a Glossary List
Usage:
<DD>...(</DD>)
Can Contain: characters, character highlighting,
A, APPLET, BR, IMG,
BASEFONT, MAP, SCRIPT, [ISINDEX], INPUT, SELECT, TEXTAREA,
DIR, DL, MENU, OL, UL, P, HR,
BLOCKQUOTE, CENTER, DIV, FORM, PRE, TABLE
Can Be Inside: DL
Attributes: none
DD gives the description corresponding to the previous DT element
or elements. A DD element should follow a DT element and should not occur alone.
See example in DL element.
HOME
MAIN
NEXT
PREV
OL Element: Ordered List
Usage:
<OL>...</OL>
Can Contain: LI
Can Be Inside: BLOCKQUOTE, BODY, CENTER, DD, DIV, FORM, LI,
TD,
TH
Attributes: COMPACT,
START, TYPE
OL defines an ordered list. Each item in the list is contained within an
LI (list item) element.
- Attributes:
- COMPACT (optional): the list should be rendered in a physical compact way. This
tends to close up text and reduce spacing between items. It is used in
Netscape Navigator, and it is not understood by most other commercial
browsers
- START="number" (optional) Specifies the
starting number for the first item in the list, where number is
an integer specifying the starting number
- TYPE="A", "a", "I", "i",
"1" (optional) Specifies the type of the marker by which the
items should be numbered. TYPE="1" is the default.
TOP
<OL COMPACT START=3
TYPE="A">
<LI>Ordered list first line. Start with the
letter C order
<LI TYPE="i">Ordered
list second line. Change type to lowercase Roman order
<LI>Ordered list
third line. IE goes back to Capitalized Alphabet order.
Netscape keeps Roman order
<LI TYPE="1">Ordered
list fourth line. Change to number
<LI>Ordered list
last line. IE goes back to Capitalized Alphabet order. Netscape
keeps Number order
</OL>
- Ordered list first line. Start with the letter C order
- Ordered list second line. Change type to lowercase Roman order
- Ordered list third line. IE goes back to Capitalized Alphabet order.
Netscape keeps Roman order
- Ordered list fourth line. Change to number
- Ordered list last line. IE goes back to Capitalized Alphabet order. Netscape
keeps Number order
HOME
MAIN
NEXT
PREV
UL Element: Unordered List
Usage:
<UL>...</UL>
Can Contain: LI
Can Be Inside: BLOCKQUOTE, BODY, CENTER, DD, DIV, FORM, LI,
TD,
TH
Attributes: COMPACT,
TYPE
UL defines an unordered list. Each item in the list is contained within an
LI (list item) element.
- Attributes:
- COMPACT (optional): the list should be rendered in a physical compact way. This
tends to close up text and reduce spacing between items. It is used in
Netscape Navigator, and it is not understood by most other commercial
browsers
- TYPE="circle", "disc", "square" (optional) Specifies the
desired type of bulleting symbol.
TOP
<UL COMPACT TYPE="circle">
<LI>Unordered list first line. Start with
circle bullet
<LI TYPE="disc">Unordered
list second line. Change to disc bullet
<LI>Unordered
list third line. IE goes back to main UL TYPE="circle" bullet.
Netscape keeps disc bullet
<LI TYPE="square">Unordered
list last line. Square bullet
</UL>
- Unordered list first line. Start with circle bullet
- Unordered list second line. Change to disc bullet
- Unordered list third line. IE goes back to main UL TYPE="circle" bullet. Netscape keeps disc bullet
- Unordered list last line. Square bullet
HOME
MAIN
NEXT
PREV
DIR Element: Directory List
Usage:
<DIR>...</DIR>
Can Contain: LI
Can Be Inside: BLOCKQUOTE, BODY, CENTER, DD, DIV, FORM, LI,
TD,
TH
Attributes: COMPACT
DIR defines a directory list--a list of short items, each usually no more
than about 20 characters. If possible, a browser may display the items in
columns across the screen, rather than one above the other (most browsers do not
do this, however, and format DIR and UL lists identically). Each item in the list is contained within an
LI (list item) element.
- Attributes:
- COMPACT (optional): the list should be rendered in a physical compact way. This
tends to close up text and reduce spacing between items. It is used in
Netscape Navigator, and it is not understood by most other commercial
browsers
TOP
<DIR>
<LI>Directory first line. Default to disc
bullet
<LI TYPE="circle">Directory
second line. Change to circle bullet
<LI>Directory
third line. IE goes back to default disc bullet. Netscape keeps circle bullet
<LI TYPE="square"=>Directory
last line. Square bullet
</DIR>
Directory first line. Default to disc bullet
Directory second line. Change to circle bullet
Directory third line. IE goes back to default disc bullet. Netscape keeps circle bullet
Directory last line. Square bullet
HOME
MAIN
NEXT
PREV
MENU Element: Menu List
Usage:
<MENU>...</MENU>
Can Contain: LI
Can Be Inside: BLOCKQUOTE, BODY, CENTER, DD, DIV, FORM, LI,
TD,
TH
Attributes: COMPACT
MENU defines a list of short menu items, each item preferably less than a
sentence long. Similar with <UL COMPACT>. Each item in the list is contained within an
LI (list item) element.
- Attributes:
- COMPACT (optional): the list should be rendered in a physical compact way. This
tends to close up text and reduce spacing between items. It is used in
Netscape Navigator, and it is not understood by most other commercial
browsers
TOP
<MENU>
<LI>Menu first line. Default to disc bullet
<LI TYPE="circle">Menu
second line. Change to circle bullet
<LI>Menu third
line. IE goes back to default disc bullet. Netscape keeps circle bullet
<LI TYPE="square">Menu
last line. Square bullet
</MENU>
HOME
MAIN
PREV
LI Element: List Item
Usage:
<LI>...(</LI>)
Can Contain: characters, character highlighting,
A, APPLET, BR, IMG,
BASEFONT, MAP, SCRIPT, [ISINDEX], INPUT, SELECT, TEXTAREA,
DIR, DL, MENU, OL, UL, P, HR,
BLOCKQUOTE, CENTER, DIV, FORM, PRE, TABLE
Can Be Inside: DIR, MENU, UL, OL
Attributes: TYPE,
VALUE
LI marks a list item within a OL, UL, DIR, or MENU
list.
- Attributes:
- TYPE="disc", "circle", "square" (within
UL, DIR, and MENU), or "I", "i", "A",
"a", "1" (within OL)
- VALUE="number" Sets the numeric counter for
the current list item, where number is an integer.