HTML Code Tutorial
Nesting Web Page Elements
Nesting is the act of placing one web page element of the same kind or like kind within another .
Web page elements that can be nested are tables, divisions and lists.
Nesting Tables
In the old days we created web pages using nested tables. Today nested tables can be used to build complicated data table structures.
<table>
<tr>
<td>
<table>
<tr>
<td></td>
</tr></table>
</td>
<td></td>
</tr>
</table>
Tables are nested by placing a table within the cell of an existing table as shown in red.
Nesting Divisions
The accepted method of building websites includes nesting divisions. Place several inside of a container division to create columns on a web page.
<div id="container">
<div id="left"></div>
<div id="middle"></div>
<div id="right"></div>
</div>
Nesting Lists
When nesting lists they can be different types. For example, you can nest a definition list inside of an unordered list .
Some of our templates use nested lists to develop drop down menus.
<ul class="art-menu">
<li><a href="#">First Level</a></li>
<li><a href="#">First Level</a>
<ul>
<li><a href="#">Second Level</a></li>
<li><a href="#">Second Level</a></li>
</ul>
</li>
<li><a href="#">First Level</a></li>
<li><a href="#">First Level</a>
<ul>
<li><a href="#">Second Level</a>
<ul>
<li><a href="#">Third Level</a> </li>
<li><a href="#">Third Level</a> </li>
<li><a href="#">Third Level</a> </li>
</ul>
</li>
<li><a href="#">Second Level</a></li>
<li><a href="#">Second Level</a></li>
</ul>
</li>
<li><a href="#">First Level</a></li>
</ul>
The code shown above produces a 3 tier drop down menu using nested lists. It sounds confusing, but the 3rd level is created by nesting a list within a nested list.
Advanced students can use the templates in our Free Template Collection to study the art of using nested lists to create drop down menus.
Back to 3 columns without Tables
Contents
HomeIntroduction
Page Structure
Basic HTML PageDoctype
The Body Tag
The Division Tag
The ID Attribute
Float Property
Navigation
Anchor TagAnchor Tag - Intradocument
Anchor Tag - Image
Text Controls
Style SheetsWorking With Fonts
The Header Tag
The Paragraph Tag
Paragraphs-Images
Using Lists
The Pre Tag
Line Break Tag
Tables
Basics of TablesColspan
Forms
Form BasicsCheck Boxes
Text Boxes
Selection Boxes
Frames
Basic FramesTarget and Scrolling
Search Engines
Miscellaneous
Meta TagsUsing Borders
Horizontal Rule
Buttons with CSS
Using Color
Color Chart
Using Images
Using Templates
Uploading HTML pages.
HTML-CSS Quizzes

