130 likes | 266 Views
With HTML you can create your own Website. This tutorial teaches you everything about HTML. For full HTML course visit our website www.training-n-development.com
E N D
Learn HTML BasicsLesson No : 07 Publisher : Attitude Academy
Chapter Summary Html List Tag Example of an unordered list, an ordered & Description list in HTML: • Unordered List: • Item • Item • Item • Item Ordered List: First item Second item Third item Fourth item • Description List: • First item Second item 2. Third item Fourth item
Unordered & Order Lists (1) An unordered list starts with the <ul> tag. Each list item starts with the <li> tag. The list items will be marked with bullets (small black circles): <body> <h2>Unordered List with Default Bullets</h2> <ul> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ul> </body> (2) An ordered list starts with the <ol> tag. Each list item starts with the <li> tag. The list items will be marked with numbers: <body> <h2>Ordered List</h2> <ol> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ol> </body>
HTML Description Lists HTML also supports description lists. A description list is a list of terms, with a description of each term. The <dl> tag defines the description list, the <dt> tag defines the term (name), and the <dd> tag describes each term: <body> <h2>A Description List</h2> <dl> <dt>Coffee</dt> <dd>- black hot drink</dd> <dt>Milk</dt> <dd>- white cold drink</dd> </dl> </body>
Nested HTML Lists List can be nested (lists inside lists): <body> <h2>A Nested List</h2> <ul> <li>Coffee</li> <li>Tea <ul> <li>Black tea</li> <li>Green tea</li> </ul> </li> <li>Milk</li> </ul> </body>
Ordered HTML Lists - The Type Attribute A type attribute can be added to an ordered list, to define the type of the marker:
Numbers Example <body> <h2> Ordered List with Numbers </h2> <ol> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ol> </body> Uppercase Letters Example <body> <h2>Ordered List with Letters</h2> <ol type="A"> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ol> </body>
Lowercase Letters Example <body> <h2>Ordered List with Lowercase Letters</h2> <ol type="a"> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ol> </body> Uppercase Roman Numbers Example <body> <h2>Ordered List with Roman Numbers</h2> <ol type="I"> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ol> </body>
Lowercase Roman Numbers Example <body> <h2>Ordered List with Lowercase Roman Numbers</h2> <ol type="i"> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ol> </body>
PRACTICAL IMPLEMENTATION