function createMenu() { // set up drop downs anywhere in the body of the page. I think the bottom of the page is better.. // but you can experiment with effect on loadtime. if (mtDropDown.isSupported()) { //================================================================================================== // create a set of dropdowns //================================================================================================== // the first param should always be down, as it is here // // The second and third param are the top and left offset positions of the menus from their actuators // respectively. To make a menu appear a little to the left and bottom of an actuator, you could use // something like -5, 5 // // The last parameter can be .topLeft, .bottomLeft, .topRight, or .bottomRight to inidicate the corner // of the actuator from which to measure the offset positions above. Here we are saying we want the // menu to appear directly below the bottom left corner of the actuator //================================================================================================== var ms = new mtDropDownSet(mtDropDown.direction.down, 0, 7, mtDropDown.reference.bottomLeft); //================================================================================================== // create a dropdown menu //================================================================================================== // the first parameter should be the HTML element which will act actuator for the menu //================================================================================================== //var oProductCategoriesMenu = ms.addMenu(document.getElementById("products_btn")); //================================================================================================== //================================================================================================== // add a sub-menu //================================================================================================== // to add a sub menu to an existing menu object, call it's addMenu method and pass it the item from // the parent menu which should act as it's actuator. To add a submenu to the fourth item of a menu // called "theMenu", you would do theMenu.addMenu(theMenu.items[3]) //================================================================================================== //var subMenu1 = menu1.addMenu(menu1.items[4]); //subMenu1.addItem("EMail Us", ""); //subMenu1.addItem("Presales FAQ", ""); //subMenu1.addItem("Customer Comments", ""); //subMenu1.addItem("ORDER NOW!", ""); var oAirConMenu = ms.addMenu(document.getElementById("air_conditioning_btn"));oAirConMenu.addItem("Mitsubishi Cassettes - FDTA Heat Pump","index.php?page=1&type=19");oAirConMenu.addItem("Mitsubishi Wall Mounted Heat Pump Air Conditioner for Conservatory or Residential Use","index.php?page=1&type=52");oAirConMenu.addItem("Mitsubishi Wall Mounts - SRK Heat Pump","index.php?page=1&type=20"); var oCateringMenu = ms.addMenu(document.getElementById("catering_btn"));oCateringMenu.addItem("Atmospheric Steamers","index.php?page=1&type=46");oCateringMenu.addItem("Bains Marie","index.php?page=1&type=26");oCateringMenu.addItem("Beverage Equipment","index.php?page=1&type=4");oCateringMenu.addItem("Boiling Tops","index.php?page=1&type=21");oCateringMenu.addItem("Chargrills","index.php?page=1&type=31");oCateringMenu.addItem("Chip Scuttles","index.php?page=1&type=32");oCateringMenu.addItem("Combi Steamers","index.php?page=1&type=29");oCateringMenu.addItem("Contact/Panini Grills","index.php?page=1&type=57");oCateringMenu.addItem("Convection Ovens","index.php?page=1&type=27");oCateringMenu.addItem("Equipment Stands","index.php?page=1&type=55");oCateringMenu.addItem("Food Warming Drawers","index.php?page=1&type=59");oCateringMenu.addItem("Fryers","index.php?page=1&type=9");oCateringMenu.addItem("Griddles","index.php?page=1&type=24");oCateringMenu.addItem("Heated Displays","index.php?page=1&type=6");oCateringMenu.addItem("Hot Cupboards","index.php?page=1&type=28");oCateringMenu.addItem("Insect Control","index.php?page=1&type=60");oCateringMenu.addItem("Microwave Ovens","index.php?page=1&type=33");oCateringMenu.addItem("Oven Ranges","index.php?page=1&type=23");oCateringMenu.addItem("Pasta Boilers","index.php?page=1&type=45");oCateringMenu.addItem("Pedestals","index.php?page=1&type=56");oCateringMenu.addItem("Prep Stations","index.php?page=1&type=58");oCateringMenu.addItem("Salamander Grills","index.php?page=1&type=25");oCateringMenu.addItem("Toasters","index.php?page=1&type=35");oCateringMenu.addItem("Water Boilers","index.php?page=1&type=22");oCateringMenu.addItem("Worktops","index.php?page=1&type=53"); var oSupplierMenu = ms.addMenu(document.getElementById("suppliers_btn")); oSupplierMenu.addItem("Arneg","index.php?page=1&manu=17");oSupplierMenu.addItem("Coolfab Remote Chills","index.php?page=1&manu=26");oSupplierMenu.addItem("Coolfab Remote Freezers","index.php?page=1&manu=25");oSupplierMenu.addItem("Coolfab Stainless Steel","index.php?page=1&manu=18");oSupplierMenu.addItem("Foster Refrigerator","index.php?page=1&manu=4");oSupplierMenu.addItem("Gamko","index.php?page=1&manu=2");oSupplierMenu.addItem("Hot Deals","index.php?page=1&manu=27");oSupplierMenu.addItem("Interlevin","index.php?page=1&manu=19");oSupplierMenu.addItem("LEC Refrigeration","index.php?page=1&manu=12");oSupplierMenu.addItem("Lincat","index.php?page=1&manu=1");oSupplierMenu.addItem("Maidaid Halcyon","index.php?page=1&manu=13");oSupplierMenu.addItem("Mitsubishi Heavy Industries Air Conditioning","index.php?page=1&manu=6");oSupplierMenu.addItem("Norpe","index.php?page=1&manu=20");oSupplierMenu.addItem("Qualitair","index.php?page=1&manu=16");oSupplierMenu.addItem("Samsung","index.php?page=1&manu=11");oSupplierMenu.addItem("Scotsman","index.php?page=1&manu=3");oSupplierMenu.addItem("Sharp","index.php?page=1&manu=10");oSupplierMenu.addItem("Whirlpool","index.php?page=1&manu=15"); //var oServicesMenu = ms.addMenu(document.getElementById("services_btn")); //oServicesMenu.addItem("Coldstore Construction", "index.php?page=5" ); //var menu4 = ms.addMenu(document.getElementById("promotions_btn")); //menu4.addItem("Graded Products", "#"); //================================================================================================== // write drop downs into page //================================================================================================== // this method writes all the HTML for the menus into the page with document.write(). It must be // called within the body of the HTML page. //================================================================================================== //mtDropDown.renderAll( "cf_menu_dropdowns" ); mtDropDown.renderAll(); } } window.onload = function() { //createMenu(); init(); } /* */