YAHOO.util.Event.onContentReady("navigationMenu", function () {

    /*
         Instantiate a MenuBar:  The first argument passed to the 
         constructor is the id of the element in the page 
         representing the MenuBar; the second is an object literal 
         of configuration properties.
    */
	
    var oMenuBar = new YAHOO.widget.MenuBar("navigationMenu", { 
                                                autosubmenudisplay: true, 
                                                hidedelay: 750, 
                                                lazyload: true,
												clicktohide: true,
												showdelay: 0});




/*
     Define an array of object literals, each containing 
     the data necessary to create a submenu.
*/

var aSubmenuData = [

    {
        id: "menuHome", 
        itemdata: [
			{ text: "Commercial Shredding", url: "../commercial/index.php" },
            { text: "Residential Shredding", url: "../residential/index.php" },
            { text: "Records Management & Storage", url: "../records-management/index.php" },
            { text: "E-Destruction", url: "../e-destruction/index.php" }            
        ]    		
	},
	

    {
        id: "menuAbout", 
        itemdata: [
			{ text: "About Us", url: "../records-management/our-team.php" },
            { text: "How we do it", url: "../records-management/how-we-do-it.php" },
            { text: "The Shredding Process", url: "../records-management/shredding-process.php" },
            { text: "Other Wiggins Companies", url: "../records-management/other-wiggins-companies.php" },
            { text: "Wiggins Shred Events", url: "../records-management/shred-events.php" } 
        ]    
    }     
	
];


/*
     Subscribe to the "beforerender" event, adding a submenu 
     to each of the items in the MenuBar instance.
*/

oMenuBar.subscribe("beforeRender", function () {
	
    if (this.getRoot() == this) {

        this.getItem(0).cfg.setProperty("submenu", aSubmenuData[0]);
        this.getItem(1).cfg.setProperty("submenu", aSubmenuData[1]);
        this.getItem(2).cfg.setProperty("submenu", aSubmenuData[2]);
        this.getItem(3).cfg.setProperty("submenu", aSubmenuData[3]);

    }

});


/*
     Call the "render" method with no arguments since the 
     markup for this MenuBar instance is already exists in 
     the page.
*/

oMenuBar.render();    

});

/***  SECOND NAVIGATION STILL ON PRIMARY LEVEL */

YAHOO.util.Event.onContentReady("navigationMenu2", function () {

    /*
         Instantiate a MenuBar:  The first argument passed to the 
         constructor is the id of the element in the page 
         representing the MenuBar; the second is an object literal 
         of configuration properties.
    */
	
    var oMenuBar = new YAHOO.widget.MenuBar("navigationMenu2", { 
                                                autosubmenudisplay: true, 
                                                hidedelay: 750, 
                                                lazyload: true,
												clicktohide: true,
												showdelay: 0});




/*
     Define an array of object literals, each containing 
     the data necessary to create a submenu.
*/

var aSubmenuData = [
/*
    {
        id: "menuWhy", 
        itemdata: [ 
            { text: "What To Shred", url: "javascript:" },
            { text: "Security", url: "javascript:" },
            { text: "Convenience", url: "javascript:" },
            { text: "100% Recycled", url: "javascript:" },
            { text: "Certificate of Destruction", url: "javascript:" },
			{ text: "Compliance", url: "javascript:" } ,
            {
                text: "PIM", 
                submenu: { 
                            id: "pim", 
                            itemdata: [
                                { text: "Yahoo! Mail", url: "http://mail.yahoo.com" },
                                { text: "Yahoo! Address Book", url: "http://addressbook.yahoo.com" },
                                { text: "Yahoo! Calendar",  url: "http://calendar.yahoo.com" },
                                { text: "Yahoo! Notepad", url: "http://notepad.yahoo.com" }
                            ] 
                        }
            
            }, 
            { text: "Member Directory", url: "http://members.yahoo.com" },
            { text: "Messenger", url: "http://messenger.yahoo.com" },
            { text: "Mobile", url: "http://mobile.yahoo.com" },
            { text: "Flickr Photo Sharing", url: "http://www.flickr.com" },
        ]
    },

    {
        id: "menuServices", 
        itemdata: [
            { text: "Drop Off Shredding", url: "javascript:" },            
            { text: "Specialty Destruction", url: "javascript:" } ,
            { text: "Tear Fests", url: "javascript:" },
			{ text: "FAQs", url: "javascript:" }               
        ]    
    } *//*,
    
    {
        id: "menuContact",
        itemdata: [
            { text: "contact1", url: "http://downloads.yahoo.com" },
            { text: "contact2", url: "http://finance.yahoo.com" },
            { text: "contact3", url: "http://health.yahoo.com" } ,
            { text: "Local", url: "http://local.yahoo.com" },
            { text: "Maps & Directions", url: "http://maps.yahoo.com" },
            { text: "My Yahoo!", url: "http://my.yahoo.com" },
            { text: "News", url: "http://news.yahoo.com" },
            { text: "Search", url: "http://search.yahoo.com" },
            { text: "Small Business", url: "http://smallbusiness.yahoo.com" },
            { text: "Weather", url: "http://weather.yahoo.com" }
        ]
    }   */                 
];


/*
     Subscribe to the "beforerender" event, adding a submenu 
     to each of the items in the MenuBar instance.
*/

oMenuBar.subscribe("beforeRender", function () {
	
    if (this.getRoot() == this) {

        this.getItem(0).cfg.setProperty("submenu", aSubmenuData[0]);
        this.getItem(1).cfg.setProperty("submenu", aSubmenuData[1]);
        this.getItem(2).cfg.setProperty("submenu", aSubmenuData[2]);
        this.getItem(3).cfg.setProperty("submenu", aSubmenuData[3]);

    }

});


/*
     Call the "render" method with no arguments since the 
     markup for this MenuBar instance is already exists in 
     the page.
*/

oMenuBar.render();    

});
	
