HTML
  Home arrow HTML arrow Page 3 - Building a Bulleted Menu Of Links: Display...
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
HTML

Building a Bulleted Menu Of Links: Display Method
By: Chrysanthus Forcha
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 3
    2009-02-23

    Table of Contents:
  • Building a Bulleted Menu Of Links: Display Method
  • Operation from the User’s Point of View
  • Implementation
  • The UL and LI elements

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Building a Bulleted Menu Of Links: Display Method - Implementation


    (Page 3 of 4 )

    For simplicity I will use the arrangement in Fig. 2 to explain how you can do the coding.

    The IDs of the UL and LI elements have been given in a way that is useful in the code.

    The IDs corresponding to the structure in Fig. 2 can be presented as follows to reflect the structure:


    LI_1

    UL_11

        LI_11

        UL_111

        LI_12

        UL_121

        LI_13

        UL_131

    LI_2

    UL_21

        LI_21

        UL_211

        LI_22

        UL_221

        LI_23

        UL_231

    LI_3

    UL_31

        LI_31

        UL_311

        LI_32

        UL_321

        LI_33

        UL_331


    Fig.5 IDs

    The IDs for the LI elements begin with LI (for List), then an underscore, and then a number. The IDs for the UL elements begin with UL (for Unordered List), then an underscore, and then a number.

    The IDs for the first level link elements are LI_1, LI_2 and LI_3. The IDs for the UL elements associated with (below LI) these LI elements are respectively, UL_11, UL_21 and UL_31. Note the extra 1 added to the corresponding numbers of the UL elements. The IDs have been given, taking into consideration the levels.

    The IDs for the LI elements inside the UL_11 element are LI_11, LI_12 and LI_13. The numbers for the UL_11 element and its first list element (LI_11) are the same. The IDs for the LI elements inside the UL_21 element are LI_21, LI_22 and LI_23. The numbers for the UL_21 element and its first list element (LI_21) are the same.

    The IDs for the LI elements inside the UL_31 element are, LI_31, LI_32 and LI_33. The numbers for the UL_31 element and its first list element (LI_31) are the same. The ID for the UL element associated with (below) the LI_11 list element is UL_111; that for LI_12 is UL_121; that for LI_21 is UL_211; that for LI_23 is UL_231, etc. Note the extra 1 added.

    The LI elements inside the UL elements for UL_111, UL_121, etc do not have IDs. In our structure (fig. 2), they cannot cause a sub-list to expand or collapse.

    The very first parent UL element that contains all the elements does not need to have an ID. No ID has been indicated for it in the ID structure.

    Each LI element has an onclick event. We shall talk about the events shortly.

    More HTML Articles
    More By Chrysanthus Forcha


     

    HTML ARTICLES

    - Hello HTML 5, Goodbye Gears
    - Comparing Browser Response to Active Client ...
    - Testing Browser Response to Active Client Pa...
    - Active Client Pages: Completing the Code for...
    - ACP and Browsers: Setting up an Example
    - How Browsers Respond to Active Client Pages
    - Completing a Tree with Active Client Pages
    - HTML Form Verification and ACP
    - Building an ACP Tree
    - Completing an ACP 3D HTML Table Image Gallery
    - Building an ACP 3D HTML Table Image Gallery
    - A Multiple Page Image Gallery with Active Cl...
    - Building an Image Gallery with Active Client...
    - Concluding a Menu for All Browsers
    - A Vertical Menu for All Browsers







    © 2003-2010 by Developer Shed. All rights reserved. DS Cluster 9 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek