The HTML ArtworkList Test Document


This is a document to display the various types of lists. It may be used with different browsers to see how lists will look under different systems. This document contains examples of:
  • an unordered list
  • an ordered list
  • a menu list
  • a directory list
  • definition list
  • nested lists
  • LI attributes
  • Multiple paragraphs in lists

  • Unordered lists

    This is an unordered list. However, there are three types of lists that typically show up with bulleted items.

    Unordered List Attribute: TYPE

    This attribute allows you to specify the type of bullet used before each list item. It was introduced by Netscape and is part of HTML 3.2.

    Setting Bullet Types using Style Sheets

    The list-style-type property can be used to control the appearance of the bullet in browsers that support style sheets.

    Unordered list:

    Ordered list:

    1. decimal
    2. lower-roman
    3. upper-roman
    4. lower-alpha
    5. upper-alpha

    If list-style-image is used and the image is not found it reverts to the default bullet character.


    Ordered List: <OL>

    Ordered lists are numbered lists. In the following example is a list of popular tomatoes.

    1. Beefsteak
    2. Better Boy
    3. Early Girl
    4. Roma
    5. Sweet 100

    Ordered List Attributes: TYPE and START

    Two attributes for ordered lists were added in HTML 3.2. These attributes were introduced by Netscape, and are supported in most versions of Netscape. However, most older browsers do not support these attributes.

    START
    Specifies a starting number for the list. The default is 1
    TYPE
    Specifies the numbering style. Allowable values are:

    Here are some examples:

    1. TYPE=1 START=9
    2. Plain arabic numbers (the default), start at 9
    1. TYPE=A START=27
    2. Capital letters, start at 27.
    1. TYPE=a START=3
    2. Lower-case letters, start at 3
    1. TYPE=I START=30
    2. Upper-case Roman numerals, start at 30
    1. TYPE=i START=100
    2. Lower-case Roman numerals, start at 100

    Menu List

    A menu list is like an unordered list, but it is supposed to be displayed in a more compact format. I've found that most browsers display it exactly like an unordered list. Here is the same list used in the unordered list section for comparison:

  • Unordered lists
  • Menu lists
  • Directory lists
  • Another menu list example:

    Some tomato pests are:

  • Colorado Potato Beetle
  • Nematodes
  • Tomato Hornworm

  • Directory List

    A directory list typically shows up with each item bulleted. Items should be no longer than 20 characters, and the HTML specification recommends that browsers should try display them in two columns. However, in my tests I have yet to find a browser that does this. Here is an example directory list:

    Tomato diseases include:

  • Cucumber Mosaic Virus
  • Fusarium Wilt
  • Verticillium Wilt
  • Tomato Spotted Wilt Virus

  • Definition Lists

    Some unusual varieties of tomatoes include:

    Big Rainbow
    Fruit on this plant may grow up to 2 pounds. They have a rainbow coloring as they mature: green on the top, yellow in the middle and red on the bottom.
    Great White
    The tomatoes on this plant ripen to a pale yellow color, similar to that of a fresh pineapple.
    Purple Calabash
    Large "ruffled" fruit characterize this plant. Ripens to a dark, almost purple color.

    Here is another example of a definition list:

    Ordered List
    A list in which each item is numbered
    Unordered List
    Lists in which each item is indicated by a bullet
    Definition List
    Lists which have a term followed by a definition. The definition is usually offset by indentation and a carriage return.
    Here is the same list with the COMPACT attribute set. Most browsers do not seem to do anything special when the COMPACT attribute is used.
    Micro-Tom
    One of the smallest tomato plants. Mature plants are less than ten inches tall.
    Pear
    There are several types of pear-shaped cherry tomatoes. Two popular varieties are Red Pear and Yellow Pear.
    Tigerette Cherry
    A striking orange and red striped cherry tomato.

    The same list without the COMPACT attribute:

    Micro-Tom
    One of the smallest tomato plants. Mature plants are less than ten inches tall.
    Pear
    There are several types of pear-shaped cherry tomatoes. Two popular varieties are Red Pear and Yellow Pear.
    Tigerette Cherry
    A striking orange and red striped cherry tomato.

    LI Extensions

    Unordered List Extensions

    Ordered List Extensions

    1. Use capital letters: <LI TYPE=A>
    2. Use lower-case letters <LI TYPE=a>
    3. Use upper-case Roman numerals <LI TYPE=I>
    4. Use lower-case Roman numerals: <LI TYPE=i>
    5. Use regular numbers (default): <LI TYPE=1>
    6. Start numbers (or letters) at a specific number. In this case, 10: <LI VALUE=10>

    Nested Lists

    It is possible to nest lists. For example, you can nest an unordered list in an ordered list. Here are some examples:
    1. Paste Tomatoes
    2. Cherry Tomatoes:

    You can also nest unordered lists within each other. Notice how some browsers change the bullets for each level:


    LI Attributes

    The TYPE attribute that affects bullet style for unordered lists may also be applied to the LI tag within a list. Note that use of this attribute with other list styles that use bullets may also result in the same effect.

    LI TYPE Attribute for UL

    Here is the TYPE attribute used with a MENU list:

  • Circle: <LI TYPE=CIRCLE>
  • Square: <LI TYPE=SQUARE>
  • Disc: <LI TYPE=DISC>
  • LI Attributes for OL: TYPE and VALUE

    The TYPE attribute that affects numbering style for ordered lists may also be applied to the LI tag within a list. the VALUE attribute may be used to reset the numbering sequence (akin to the START attribute for OL). Some examples:

    1. Use capital letters: <LI TYPE=A>
    2. Use lowercase letters <LI TYPE=a>
    3. Use uppercase Roman numerals <LI TYPE=I>
    4. Use lowercase Roman numerals: <LI TYPE=i>
    5. Use regular numbers (default): <LI TYPE=1>
    6. Start numbers (or letters) at a specific number. In this case, 10: <LI VALUE=10>

    Multiple Paragraphs in Lists

    Items in lists may need to be longer than a single paragraph. You may separate paragraphs in a single list item through the use of the P tag. However, many browsers may display the item with a blank line between the paragraphs. This may look strange since many browsers do not place a blank line between items in a list. Another alternative is to separate paragraphs with a BR tag. However, you run the risk of obscuring your paragraph breaks if you choose this route. Take a look at this document in several different browsers to gain a better understanding of the ways that multiple paragraphs in a list are treated.

    Unordered List

    Items with Multiple-Paragraphs in an Ordered List

    Items with Multiple-Paragraphs in an Definition List

    This is a definition list.
    I separate this definition item into two paragraphs using a P tag.

    Here is the second paragraph in our first item.

    Now my second item.
    This definition item is divided into two sections using a second DD element.
    Here is the second DD element.

    [HTML CD Home Page]

    Vivian Neou, vivian@catalog.com
    Copyright © 1999 Vivian Neou