Home >> FAQs/Tutorials >> XHTML Tutorials and Tips >> Index

XHTML Tutorial - Un-ordered List Item Markers

By: FYIcenter.com

(Continued from previous topic...)

How To Use Different Markers on Unordered List Items?

By default, browsers will use solid dots as the item markers for unordered lists. If you want to change them to something else, like tiny squares, you need to use CSS properties. Here is a tutorial example showing you how to set item markers to be tiny squares:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
 <head>
  <title>List Item Markers</title>
 </head>
 <body>
  <h4>Search Engines:</h4>
  <ul style="list-style-type: square">
  <li>google.com</li>
  <li>yahoo.com</li>
  <li>msn.com</li>
  <li>ask.com</li>
  </ul>
 </body>
</html>

If you save the above document as square_item_marker.html, and view it with Internet Explorer, you will see a list of 4 items with tiny squares as item markers as shown below:
            Item Markers

  1. What Are List Elements?
  2. What Is an "ol" Tag/Element?
  3. What Is a "li" Tag/Element?
  4. Can Multiple Paragraphs Be Included in a List Item?
  5. What Is a "ul" Tag/Element?
  6. What Is a "dl" Tag/Element?
  7. Can List Elements Be Nested?
  8. How To Use Different Markers on Ordered List Items?
  9. How To Use Different Markers on Unordered List Items?


Selected Developer Jobs:

More...