GUI Components JavaScript DHTML

        "http://www.w3.org/TR/html4/strict.dtd">

    
        
        Example 3: Grouped MenuItem Instances From Existing Markup
        
        
        
        
        
 
        
        
            body { margin:.5em; }
        
        
        
        
        
        
        
        
        
        
        
        
            YAHOO.example.onWindowLoad = function(p_oEvent) {
                var oMenu = new YAHOO.widget.Menu("menuwithgroups", { fixedcenter: true });
                oMenu.render();
    
                oMenu.show();
            }
            YAHOO.util.Event.addListener(window, "load", YAHOO.example.onWindowLoad);
            
        
    
    
        

Example 3: Grouped MenuItem Instances From Existing Markup [Examples Home]


        

This example demonstrates how to group MenuItem instances.  The Menu API also supports building a menu like this using nothing but JavaScript.


        
            
                
                    Yahoo! Mail
                    Yahoo! Address Book
                    Yahoo! Calendar
                    Yahoo! Notepad
                
                

                        Yahoo! Local
                        Yahoo! Maps
                        Yahoo! Travel
                        Yahoo! Shopping
                    

                

                        Yahoo! Messenger
                        Yahoo! 360
                        Yahoo! Groups
                        Yahoo! Photos
                    

            

        
        
    

           
         
  
yui.zip( 3,714 k)