Home arrow HTML arrow Page 3 - Layout for a Menu for All Browsers
HTML

Layout for a Menu for All Browsers


In this part of the series, I explain the nature of the menu items and how they fit into the tables of the sub menus and main menu. I spend the rest of the article talking about the style attribute of the tables of the sub menus. A lot of the design in this series lies in the configuration of the tables. In fact, we shall spend more time talking about the configuration of the tables than we shall spend talking about the JavaScript code.

Author Info:
By: Chrysanthus Forcha
Rating: 4 stars4 stars4 stars4 stars4 stars / 4
May 13, 2009
TABLE OF CONTENTS:
  1. · Layout for a Menu for All Browsers
  2. · The Style Attributes
  3. · Tables for the Drop Down Menus
  4. · More on the Second Drop Down Menu

print this article
SEARCH DEVARTICLES

TOOLS YOU CAN USE

advertisement
Layout for a Menu for All Browsers - Tables for the Drop Down Menus
(Page 3 of 4 )

Each table for a drop down menu is given the position property. The value for the position property of these tables is "absolute." The left and top properties are deliberately omitted. Because of this condition, everything being equal, the table remains where you place it in the cell of the main table (for the sub menus). The z-index property is not given. Since the main table has a z-index property value of 10, each of these tables is at a z-index level of 10.

The initial and default value of the display property for each of these tables is "none." When you want to see a drop down menu, this property value is changed to "block." That is, when the mouse pointer goes over the corresponding main menu item (of the horizontal bar), this value is change to "block."

The Second Drop Down Menu

When the mouse pointer goes over the second main menu item, you see the second drop down menu. This is the outline of the resulting table for this menu:


Fig. 12.1


When the second drop down menu first appears, the display nature is as shown above. You have a one-row table with three cells. The first cell has a five-row table of one column. This inner table is the drop down menu. The position property of the outer table is “position:absolute.” With this property and its value, if the left and top properties are omitted, the table stays where you place it. This is with respect to the main table. The value of the position property of the inner table we are seeing is also "absolute," for the same reason as above, but this time with respect to the outer table (above).

The initial and default value of the display property of the outer table is "none." When the second drop down menu is to be seen, this value is changed to "block." When the value is "block," the situation is as shown above (fig 12.1). The value of the display property of the inner table above is always "block." So, whenever the outer table is displayed, you see the above inner table.


blog comments powered by Disqus
HTML ARTICLES

- HTML5 Boilerplate: Working with jQuery and M...
- HTML5 Boilerplate Introduction
- New API Platform for HTML5
- BBC Adopts HTML 5, Mozilla Addresses Issues
- Advanced Sticky Footers in HTML and CSS
- HTML and CSS Sticky Footers
- Strategy Analytics Predicts HTML5 Phones to ...
- HTML5 Guidelines for Web Developers
- Learning HTML5 Game Programming
- More Engaging CSS3 and HTML Background Effec...
- Engaging HTML and CSS3 Background Effects
- More Web Columns with CSS3 and HTML
- Columns with CSS3 and HTML
- Creating Inline-Block HTML Elements with CSS
- Drag and Drop in HTML5: Parsing Local Files

Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 



© 2003-2012 by Developer Shed. All rights reserved. DS Cluster 11 - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials