/*** 
This is the menu creation code - place it right after you body tag
Feel free to add this to a stand-alone js file and link it to your page.
**/

//Extra code to find position:
function findPos(){
  if(bw.ns4){   //Netscape 4
    x = document.layers.layerMenu.pageX
    y = document.layers.layerMenu.pageY
  }else{ //other browsers
    x=0; y=0; var el,temp
    el = bw.ie4?document.all["divMenu"]:document.getElementById("divMenu");
    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]
}

pos = findPos()

//Menu object creation
oCMenu=new makeCM("oCMenu") //Making the menu object. Argument: menuname

//Menu properties   
oCMenu.pxBetween=0
pos = findPos()
oCMenu.fromLeft=pos[0]
oCMenu.fromTop=pos[1]
//We also need to "re place" the menu on resize. So:
oCMenu.onresize="pos = findPos(); oCMenu.fromLeft=pos[0]; oCMenu.fromTop=pos[1]"

oCMenu.rows=0 
oCMenu.menuPlacement=0

oCMenu.offlineRoot="file:///C|/Documents and Settings/Lef/My Documents/My Anchora Projects/harvard_apparatus/site/" 
oCMenu.onlineRoot="/" 
oCMenu.resizeCheck=1 
oCMenu.wait=1000 
oCMenu.fillImg="cm_fill.gif"
oCMenu.zIndex=0

//Background bar properties
oCMenu.useBar=0
oCMenu.barWidth="menu"
oCMenu.barHeight="menu" 
oCMenu.barClass="clBar"
oCMenu.barX="menu"
oCMenu.barY="menu"
oCMenu.barBorderX=0
oCMenu.barBorderY=0
oCMenu.barBorderClass=""

//Level properties - ALL properties have to be spesified in level 0
oCMenu.level[0]=new cm_makeLevel() //Add this for each new level
oCMenu.level[0].width=220
oCMenu.level[0].height=20
oCMenu.level[0].regClass="clLevel0"
oCMenu.level[0].overClass="clLevel0over"
oCMenu.level[0].borderX=0 
oCMenu.level[0].borderY=0
oCMenu.level[0].borderClass=0
oCMenu.level[0].offsetX=-50
oCMenu.level[0].offsetY=-80
oCMenu.level[0].borderClass="clLevel0border"
oCMenu.level[0].borderX=1 
oCMenu.level[0].borderY=1
oCMenu.level[0].rows=0
oCMenu.level[0].align="right" 
oCMenu.level[0].arrow="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" 
oCMenu.level[0].arrowWidth=4
oCMenu.level[0].arrowHeight=8

//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
oCMenu.level[1]=new cm_makeLevel() //Add this for each new level (adding one to the number)
oCMenu.level[1].width=500
oCMenu.level[1].height=20
oCMenu.level[1].regClass="clLevel1"
oCMenu.level[1].overClass="clLevel1over"
oCMenu.level[1].style=""
oCMenu.level[1].align="right" 
oCMenu.level[1].offsetX=0
oCMenu.level[1].offsetY=10
oCMenu.level[1].borderClass="clLevel1border"
oCMenu.level[1].borderX=1 
oCMenu.level[1].borderY=1
oCMenu.level[1].rows=0
oCMenu.level[1].align="bottom" 

/******************************************
Menu item creation:
myCoolMenu.makeMenu(name, parent_name, text, link, target, width, height, regImage, overImage, regClass, overClass , align, rows, nolink, onclick, onmouseover, onmouseout) 
*************************************/
oCMenu.makeMenu('top0','','Dialyse/Pr&eacute;paration d’&eacute;chantillons/Electrophor&egrave;se <img src="http://www.harvardapparatus.fr/images/layout/arrow_red.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30613&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30613&top_category=30613&breadcrumb_trail=Dialysis+%2F+Sample+Prep+%2F+SPE&breadcrumb_categoryIds=30613','',220,30,'','','clLevel0Special','clLevel0overSpecial')
oCMenu.makeMenu('top1','','Pompes pousse seringues/Pompes péristaltiques <img src="http://www.harvardapparatus.fr/images/layout/arrow_red.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=11051&storeId=10001&categoryId=37295&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=37295&top_category=37295&breadcrumb_trail=Syringe+Pumps%2FPeristaltic+Pumps&breadcrumb_categoryIds=37295','',220,30,'','','clLevel0Special','clLevel0overSpecial')
oCMenu.makeMenu('top2','','Respirateurs <img src="http://www.harvardapparatus.fr/images/layout/arrow_red.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=31501&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=31501&top_category=31501&breadcrumb_trail=Ventilators&breadcrumb_categoryIds=31501','',220,20,'','','clLevel0Special','clLevel0overSpecial')
oCMenu.makeMenu('top4','','Anesth&eacute;sie gazeuse <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30584&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30584&top_category=30584&breadcrumb_trail=Anesthesia+Equipment&breadcrumb_categoryIds=30584')
oCMenu.makeMenu('top5','','Contention et manipulation animale <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30645&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30645&top_category=30645&breadcrumb_trail=Animal+Handling+Products&breadcrumb_categoryIds=30645')
oCMenu.makeMenu('top6','','Recherche comportementale <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30604&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30604&top_category=30604&breadcrumb_trail=Behavior+Research+Products&breadcrumb_categoryIds=30604')
oCMenu.makeMenu('top7','','Mesures biologiques <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30487&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30487&top_category=30487&breadcrumb_trail=Biological+Measurement+Products&breadcrumb_categoryIds=30487')
oCMenu.makeMenu('top8','','Cardiovasculaire <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30685&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30685&top_category=30685&breadcrumb_trail=Cardiovascular+Products&breadcrumb_categoryIds=30685')
oCMenu.makeMenu('top9','','Biologie cellulaire <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30510&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30510&top_category=30510&breadcrumb_trail=Cell+Biology+Products&breadcrumb_categoryIds=30510')
oCMenu.makeMenu('top25','','Micro incubation/Micro-injection in vitro <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30772&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30772&top_category=30772&breadcrumb_trail=Microincubation+%2F+Microinjectors&breadcrumb_categoryIds=30772','',220,30)
oCMenu.makeMenu('top10','','Perfusion/Prélèvement in vivo <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=32201&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=32201&top_category=32201&breadcrumb_trail=Delivery+%26+Sampling+Products&breadcrumb_categoryIds=32201')
oCMenu.makeMenu('top11','','Electrophysiologie in vitro <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30556&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30556&top_category=30556&breadcrumb_trail=Electrophysiology+Products&breadcrumb_categoryIds=30556')
oCMenu.makeMenu('top12','','Petit équipement de laboratoire <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30692&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30692&top_category=30692&breadcrumb_trail=General+Laboratory+Products&breadcrumb_categoryIds=30692')
oCMenu.makeMenu('top13','','Homéothermie/Contrôle de température <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30720&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30720&top_category=30720&breadcrumb_trail=Homeothermic%2FTemperature+Control&breadcrumb_categoryIds=30720','',220,30)
oCMenu.makeMenu('top14','','Tissus et organes isolés <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30737&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30737&top_category=30737&breadcrumb_trail=Isolated+Organ+%26+Isolated+Tissue&breadcrumb_categoryIds=30737')
oCMenu.makeMenu('top15','','Biologie moléculaire <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30782&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30782&top_category=30782&breadcrumb_trail=Molecular+Biology+Products&breadcrumb_categoryIds=30782')
oCMenu.makeMenu('top16','','Neurosciences <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30806&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30806&top_category=30806&breadcrumb_trail=Neuroscience+Products&breadcrumb_categoryIds=30806')
oCMenu.makeMenu('top17','','Mesure de pression sanguine non invasive <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=33756&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=33756&top_category=33756&breadcrumb_trail=Non-Invasive+Blood+Pressure&breadcrumb_categoryIds=33756','',220,30)
oCMenu.makeMenu('top18','','Modèles atomiques CPK <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30666&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30666&top_category=30666&breadcrumb_trail=CPK%AE+Atomic+Models&breadcrumb_categoryIds=30666')
oCMenu.makeMenu('top19','','Physiologie animale <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30830&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30830&top_category=30830&breadcrumb_trail=Physiology+Products&breadcrumb_categoryIds=30830')
oCMenu.makeMenu('top20','','Respiration in vivo <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=33822&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=33822&top_category=33822&breadcrumb_trail=Respiratory+Products&breadcrumb_categoryIds=33822')
oCMenu.makeMenu('top21','','Stéréotaxie <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30896&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30896&top_category=30896&breadcrumb_trail=Stereotaxic+Instruments&breadcrumb_categoryIds=30896')
oCMenu.makeMenu('top22','','Equipement chirurgical <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30906&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30906&top_category=30906&breadcrumb_trail=Surgical+Equipment&breadcrumb_categoryIds=30906')
oCMenu.makeMenu('top23','','Instruments chirurgicaux <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=30943&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=30943&top_category=30943&breadcrumb_trail=Surgical+Instruments&breadcrumb_categoryIds=30943')
oCMenu.makeMenu('top24','','Tubes/Connecteurs <img src="http://www.harvardapparatus.fr/images/layout/arrow_yellow.gif" />','http://www.harvardapparatus.com/webapp/wcs/stores/servlet/CategoryDisplay?catalogId=10051&storeId=10001&categoryId=31005&langId=-1&division=HAI&pageId=Categories&top=Y&parent_category_rn=31005&top_category=31005&breadcrumb_trail=Tubing+%26+Connectors&breadcrumb_categoryIds=31005')

//Leave this line - it constructs the menu
oCMenu.construct()		
