// preload btn background btn_over_background = newImage("gfx/hnav-btn_over.jpg"); //Menu object creation xMenu=new makeCM("xMenu") //Making the menu object. Argument: menuname xMenu.frames = 0 //Menu properties xMenu.pxBetween=0 //Using the cm_page object to place the menu ---- xMenu.fromLeft=0 xMenu.fromTop=0 xMenu.rows=1 xMenu.menuPlacement=0 xMenu.offlineRoot="/" xMenu.onlineRoot="/" xMenu.resizeCheck=1 xMenu.wait=500 xMenu.fillImg="cm_fill.gif" xMenu.zIndex=0 //Background bar properties xMenu.useBar=0 xMenu.barWidth="100%" xMenu.barHeight="menu" xMenu.barClass="clBar" xMenu.barX=0 xMenu.barY="menu" xMenu.barBorderX=0 xMenu.barBorderY=0 xMenu.barBorderClass="" //Level properties - ALL properties have to be spesified in level 0 xMenu.level[0]=new cm_makeLevel() //Add this for each new level xMenu.level[0].width=110 xMenu.level[0].height=26 xMenu.level[0].regClass="clLevel0" xMenu.level[0].overClass="clLevel0over" xMenu.level[0].borderX=0 xMenu.level[0].borderY=0 xMenu.level[0].borderClass="clLevel0border" xMenu.level[0].offsetX=0 xMenu.level[0].offsetY=1 xMenu.level[0].rows=0 xMenu.level[0].arrow=0 xMenu.level[0].arrowWidth=0 xMenu.level[0].arrowHeight=0 xMenu.level[0].align="bottom" //EXAMPLE SUB LEVEL[1] PROPERTIES - You have to specify the properties you want different from LEVEL[0] - If you want all items to look the same just remove this xMenu.level[1]=new cm_makeLevel() //Add this for each new level (adding one to the number) xMenu.level[1].width= xMenu.level[0].width-2 // (bordure en moins) xMenu.level[1].height=19 xMenu.level[1].regClass="clLevel1" xMenu.level[1].overClass="clLevel1over" xMenu.level[1].borderX=1 xMenu.level[1].borderY=1 xMenu.level[1].align="right" xMenu.level[1].offsetX=-1 // -(xMenu.level[0].width-2)/2+20 xMenu.level[1].offsetY=0 xMenu.level[1].borderClass="clLevel1border" xMenu.level[1].arrow="gfx/hnav-rarrow.gif" xMenu.level[1].arrowWidth=4 xMenu.level[1].arrowHeight=7 //EXAMPLE SUB LEVEL[2] PROPERTIES - You have to spesify the properties you want different from LEVEL[1] OR LEVEL[0] - If you want all items to look the same just remove this xMenu.level[2]=new cm_makeLevel() //Add this for each new level (adding one to the number) xMenu.level[2].width=150 xMenu.level[2].height=19 xMenu.level[2].offsetX=0 xMenu.level[2].offsetY=0 //xMenu.level[2].regClass="clLevel2" //xMenu.level[2].overClass="clLevel2over" //xMenu.level[2].borderClass="clLevel2border" xMenu.level[3]=new cm_makeLevel() xMenu.level[3].width=180 /****************************************** Menu item creation: myCoolMenu.makeMenu(name, parent_name, text, link, target, width, height, regImage, overImage, regClass, overClass , align, rows, nolink, onclick, onmouseover, onmouseout) ******************************************/ xMenu.makeMenu('comp','','Company','contentlist.php?type=company') xMenu.makeMenu('company47','comp','Who are we ?','content.php?id=47') xMenu.makeMenu('company29','comp','Careers','content.php?id=29') xMenu.makeMenu('company28','comp','Strategic Axis','content.php?id=28') xMenu.makeMenu('partner','comp','Partners','contentlist.php?type=partenaire') xMenu.makeMenu('becomepartner','partner','Become a partner','become_partner.php') xMenu.makeMenu('prod','','Products','contentlist.php?type=product') xMenu.makeMenu('softwares','prod','Software','contentlist.php?type=product&ptype=1') xMenu.makeMenu('product11','softwares','PC Login Pro Suite 5','pc-login-pro-suite-5.html') xMenu.makeMenu('product89','softwares','Virtual Network Access 5','virtual-network-access-5.html') xMenu.makeMenu('product41','softwares','Secure Bio Drive Software','secure-bio-drive-software.html') xMenu.makeMenu('product94','softwares','XELIOS PowerCrypt','xelios-powercrypt.html') xMenu.makeMenu('hardwares','prod','Hardware','contentlist.php?type=product&ptype=2') xMenu.makeMenu('biosensors','hardwares','Biometric sensors','contentlist.php?type=product&ptype=2&pstype=2') xMenu.makeMenu('product17','biosensors','MSO 1300X','mso-1300x.html') xMenu.makeMenu('product16','biosensors','MSO 300X and 350X','mso-300x-and-350x.html') xMenu.makeMenu('product90','biosensors','TCRE Eikon','tcre-eikon.html') xMenu.makeMenu('product38','biosensors','XELIOS BioKeyboard','xelios-biokeyboard.html') xMenu.makeMenu('smartcards','hardwares','Smart cards, readers and tokens','contentlist.php?type=product&ptype=2&pstype=3','','','30') xMenu.makeMenu('product36','smartcards','Gemalto e-gate','gemalto-e-gate.html') xMenu.makeMenu('product32','smartcards','Cardman readers','cardman-readers.html') xMenu.makeMenu('product19','smartcards','XELIOS Token','xelios-token.html') xMenu.makeMenu('biostorage','prod','Biometric storage','contentlist.php?type=product&ptype=4') xMenu.makeMenu('product13','biostorage','Secure Bio Drive','secure-bio-drive.html') xMenu.makeMenu('product14','biostorage','Secure Bio Drive External','secure-bio-drive-external.html') xMenu.makeMenu('product91','biostorage','Stealth MXP','stealth-mxp.html') xMenu.makeMenu('solutions','','Solutions','contentlist.php?type=solution') xMenu.makeMenu('sol77','solutions','Solutions for governments','content.php?id=77','','','30') xMenu.makeMenu('sol86','solutions','Solution for banking institutions','content.php?id=86','','','30') xMenu.makeMenu('sol87','solutions','Solution for enterprises','content.php?id=87','','','30') xMenu.makeMenu('sol92','solutions','Solution for healthcare establishments','content.php?id=92','','','30') xMenu.makeMenu('services','','Services','contentlist.php?type=product&ptype=3') xMenu.makeMenu('services_15','services','XELIOS Training','content.php?id=54') xMenu.makeMenu('services_16','services','Technical Support','content.php?id=55') xMenu.makeMenu('services_17','services','Before sales service','content.php?id=56') xMenu.makeMenu('glossary','services','Glossary','glossary.php') xMenu.makeMenu('press','','Communication','contentlist.php?type=presse') xMenu.makeMenu('press_event','press','Events','contentlist.php?type=event') xMenu.makeMenu('press_press','press','Press','contentlist.php?type=presse') xMenu.makeMenu('newsletter','press','Newsletter','newsletter_subscribe.php') xMenu.makeMenu('press_market','press','Marketing items','download.php?grp=market') xMenu.makeMenu('contact','','Contact','contact.php') xMenu.makeMenu('contactcontact','contact','Contact us','contact.php') xMenu.makeMenu('contactlist','contact','Contact list','contact.php?list=1') xMenu.construct() //Extra code to find position: function findPos(num){ //alert(num) if(bw.ns4){ //Netscape 4 x = document.layers["layerMenu"+num].pageX y = document.layers["layerMenu"+num].pageY }else{ //other browsers x=0; y=0; var el,temp el = bw.ie4?document.all["divMenu"+num]:document.getElementById("divMenu"+num); if(el.offsetParent){ temp = el while(temp.offsetParent){ //Looping parent elements to get the offset of them as well temp=temp.offsetParent; x+=temp.offsetLeft y+=temp.offsetTop; } } x+=el.offsetLeft y+=el.offsetTop } //Returning the x and y as an array return [x,y] } function placeElements(){ //Changing the position of ALL top items: pos = findPos(0) xMenu.m["comp"].b.moveIt(pos[0],pos[1]) pos = findPos(1) xMenu.m["prod"].b.moveIt(pos[0],pos[1]) pos = findPos(2) xMenu.m["solutions"].b.moveIt(pos[0],pos[1]) pos = findPos(3) xMenu.m["services"].b.moveIt(pos[0],pos[1]) pos = findPos(4) xMenu.m["press"].b.moveIt(pos[0],pos[1]) pos = findPos(5) xMenu.m["contact"].b.moveIt(pos[0],pos[1]) //Setting the fromtop value xMenu.fromTop = pos[1] } placeElements() //Setting it to re place the elements after resize - the resize is not perfect though.. xMenu.onafterresize="placeElements()"