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

XHTML Tutorial - Multiple Paragraphs Be Included in a List Item

By: FYIcenter.com

(Continued from previous topic...)

Can Multiple Paragraphs Be Included in a List Item?

Yes. You can include multiple paragraphs in a single list item, because "li" is a flow type element, which can have block elements and inline elements. The tutorial example below shows you how a list item can have two paragraphs:

<?xml version="1.0" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  <title>Lists with Block Items</title>
  <h3>Tutorial Tips by FYIcenter.com:</h3>
  <li><p><strong>XHTML Tutorials/FAQs</strong>
   - 116 Entries</p>
  <p>Topics includes: Introduction To XHTML 1.0, 
Introduction To Tag and Attribute Syntax,
Introduction To Element Content Syntax, 
Document Structure and Head Level Tags, 
Body Tag and Block Level Tags,
Understanding In-line Elements and Tags, etc.</p>
  <li><p><strong>PHP Tutorials/FAQs</strong>
   - 204 Entries</p>
  <p>Downloading and Installing PHP,
Understanding and Managing Cookies,
Understanding and Using Sessions,
Processing Web Forms, 
Working with MySQL Database, 
Uploading Files to Web Servers, etc.</p>

If you save the above document as block_list_item.html, and view it with Internet Explorer, you will see a list of items with multiple paragraphs as shown below:
            Block List Items

(Continued on next topic...)

  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: