List Item

Support Key: [2|3|3.2|4] [X1|X1.1] [IE1|M1|N1|O2.1]
What is it?
Attributes
Tag Example
Parent/Content Model
Tips & Tricks
Browser Peculiarities
= Index DOT Html by Brian Wilson =
Main Index | Element Tree | Element Index | HTML Support History



   Quick Statistics   
End Tag:
   Optional
Standards Details:
In all HTML 4.x/XHTML DTDs
XHTML Modules:
List
CSS 'display' Type:
"list-item"
CSS Mapping:
display: list-item, list-style, margin-left
Default Rendering:
A bullet-type marker for UL/DIR/MENU lists, and an iterative/ordered marker for OL lists.
Official Docs:
HTML 4.x, XHTML 1.1

What is it?
The List Item (LI) is only used as a sub-element of a list type. DIR, MENU, OL, and UL all use it to mark a component of their structure. The LI element is the only content of these list structures. The closing </li> tag is optional in HTML (required in XHTML), as it is implied by the subsequent <li> or end list tags.

Common Attributes
%Core%
[2|3|3.2|4] [X1|X1.1] [IE3|M|N4B2|O3.5]
%Accessibility%
[2|3|3.2|4] [X1|X1.1] [IE4B1|M|N6|O5]
%Events%
[2|3|3.2|4] [X1|X1.1] [IE4B1|M|N6B1|O4]
%Language%
[2|3|3.2|4] [X1|X1.1] [IE4|M|N6B1|O]
%Editing%
[2|3|3.2|4] [X1|X1.1] [IE5.5|M|N|O]

Specific Attributes
Note: These attributes only apply when UL and OL are the parent elements.
Align
[2|3|3.2|4] [X1|X1.1] [IE4|M|N|O4]
Standards Details: NA
Required? No
Description:
This indicates the horizontal alignment of the content in this block element relative to the browser window.
Values: Left [DEFAULT] | Center | Right
Clear
[2|3|3.2|4] [X1|X1.1] [IE|M|N|O2.1-6.x]
Standards Details: NA
Required? No
Description:
This attribute helps an author in situations with floating objects (images, tables, etc.) produced through the Left and Right ALIGN attributes. It allows content to stop being flowed around the floated element.
Values:
   None [DEFAULT - No special line breaking effects are applied relative to the floating element.]
   Left [breaks line after this element and moves down vertically until the left margin is clear of floated objects.]
   Right [breaks line after this element and moves down vertically until the right margin is clear of floated objects.]
   All [breaks line after this element and moves down vertically until both margins are clear of floated objects.]
Height
[2|3|3.2|4] [X1|X1.1] [IE|M|N|O4-6.x]
Standards Details: NA
Required? No
Description:
This attribute explicitly specifies the height of this block element in pixels.
Values: Positive integers.
SDAForm
[2|3|3.2|4] [X1|X1.1] [IE|M|N|O]
Standards Details: NA
Required? No
Description:
This is an SGML Document Access (SDA) attribute. SDA attributes are designed to transform HTML (and other SGML-based documents) to the ICADD DTD - which is used in creating accessible documents for users with visual disabilities (rendering in Braille, large print, speech synthesis, etc.) The attribute value specifies the name of the element to convert this element to in the SDA element group (in this case the 'LItem' element - "List Item NOTE, Note in Text".)
Value: LItem (Denotes 'List Item NOTE, Note in Text' in SDA.)
Type
[2|3|3.2|4] [X1|X1.1] [IE1|M|N1|O2.1]
Standards Details: Deprecated in HTML 4.x/XHTML 1.0; Dropped in XHTML 1.1 in favor of CSS
Required? No
Description:
The Type attribute indicates different ordering label schemes to be used instead of the default values for each element in a UL or OL. The TYPE attribute to the LI element is only applicable to UL and OL and accepts values appropriate for each list type. When used at the LI level, all subsequent list labels will carry the new TYPE scheme unless set again by a later LI TYPE attribute.
Values:
Ordered Lists (OL) values:
     A [capital letters]
     a [lower-case letters]
     I [large roman numerals]
     i [small roman numerals]
     1 [default numbering scheme.]
Unordered Lists (UL) values:
     disc [default solid bullet]
     square [solid square]
     circle [hollow bullet]
     round [also a hollow bullet]
Value
[2|3|3.2|4] [X1|X1.1] [IE1|M|N1|O2.1]
Standards Details: Deprecated in HTML 4.x/XHTML 1.0; Dropped in XHTML 1.1 in favor of CSS
Required? No
Description:
This attribute is used to indicate a number other than the incremented value for the current List Item (LI) in an Ordered List (OL.) It is thus possible to create a non-sequential list. Values are automatically converted to the TYPE attribute, if present, of the parent OL element or current LI element.
Values: Decimal integers; some browsers may even accept "0" or negative numbers as valid (see browser peculiarities.)
Width
[2|3|3.2|4] [X1|X1.1] [IE|M|N|O4-6.x]
Standards Details: NA
Required? No
Description:
This attribute explicitly specifies the width of this block element in pixels.
Values: Positive integers.
Example
<ol>
   <li>List item 1</li>
   <li value="5" type="A">List item E</li>
   <li>List item 3</li>
</ol>
Parent Model
<dir> | <menu> | <ol> | <ul>
Content Model
Dir/Menu Context
%In-line Content%
Ol/Ul Context
%In-line Content% | %Block Content%
Tips & Tricks Browser Peculiarities
Boring Copyright Stuff...