/*** 
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
//Using the cm_page object to place the menu ----
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|/My Documents/MY WEBS/GDAS_2006/" 
oCMenu.onlineRoot="/" 
oCMenu.resizeCheck=1 
oCMenu.wait=1000 
oCMenu.fillImg="images/gif/cm_fill.gif"
oCMenu.zIndex=0

//Background bar properties
oCMenu.useBar=1
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=128
oCMenu.level[0].height=25 
oCMenu.level[0].regClass="clLevel0"
oCMenu.level[0].overClass="clLevel0over"
oCMenu.level[0].borderX=1
oCMenu.level[0].borderY=1
oCMenu.level[0].borderClass="clLevel0border"
oCMenu.level[0].offsetX=0
oCMenu.level[0].offsetY=-70
oCMenu.level[0].rows=0
oCMenu.level[0].arrow=0
oCMenu.level[0].arrowWidth=0
oCMenu.level[0].arrowHeight=0
oCMenu.level[0].align="left"





//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].offsetX=0
oCMenu.level[1].offsetY=-25


//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
oCMenu.level[2]=new cm_makeLevel() //Add this for each new level (adding one to the number)



/******************************************
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','','Home','index.htm','')
  
	
oCMenu.makeMenu('top1','','How we operate','operate.htm')
	
	
oCMenu.makeMenu('top2','','Adoption')
	oCMenu.makeMenu('sub21','top2','How it works','adopt.htm')
	oCMenu.makeMenu('sub22','top2','Apply online','adopt_apply.htm')
	oCMenu.makeMenu('sub23','top2','Special Danes looking for homes','special_danes.htm','','','40')
	oCMenu.makeMenu('sub24','top2','Other special dogs looking for homes','special_dogs.htm','','','40')	

oCMenu.makeMenu('top3','','How you can help')
	oCMenu.makeMenu('sub30','top3','Transporting','transport.htm')
	oCMenu.makeMenu('sub31','top3','Homechecking','homecheck.htm')
	oCMenu.makeMenu('sub32','top3','Fostering','foster.htm')
	oCMenu.makeMenu('sub34','top3','Sponsor a Dane','sponsor.htm')
	oCMenu.makeMenu('sub35','top3','Become a member')
		oCMenu.makeMenu('sub350','sub35','New Member','member.htm')
		oCMenu.makeMenu('sub351','sub35','Renew membership','member_renew.htm')
	oCMenu.makeMenu('sub36','top3','Make a bequest','bequest.htm')
	oCMenu.makeMenu('sub37','top3','Make a donation','donate.htm')
	oCMenu.makeMenu('sub38','top3','Our merchandise')
		oCMenu.makeMenu('sub380','sub38','Merchandise','shop.asp')
		oCMenu.makeMenu('sub381','sub38','Terms of Business','info/terms.htm')
	oCMenu.makeMenu('sub39','top3','Our Charity Shop','charity_shop.htm')
	
	oCMenu.makeMenu('sub310','top3','Shopping partners','partners.htm')
	oCMenu.makeMenu('sub311','top3','Buy a Gift for a Dane in care','Danegift.asp','','','40')	
	oCMenu.makeMenu('sub312','top3','Send us your used stamps','stamps.htm','','','40')
	oCMenu.makeMenu('sub313','top3','Donate your used ink cartridges','ink.htm','','','40')

oCMenu.makeMenu('top4','','Caring for Danes')
	oCMenu.makeMenu('sub40','top4','General Care','care.htm')
	oCMenu.makeMenu('sub41','top4','Common medical complaints','','','','40')
		oCMenu.makeMenu('sub410','sub41','Bloat - Gastric Torsion','bloat.htm','','','40')
		oCMenu.makeMenu('sub411','sub41','Canine Dilated Cardiomyopathy','cdc.htm','','','40')
		oCMenu.makeMenu('sub412','sub41','Molecular test for Canine Dilated Cardiomyopathy','mcdc.htm','','','55')
		oCMenu.makeMenu('sub413','sub41','Flea allergy and control','flea.htm','','','40')
		oCMenu.makeMenu('sub414','sub41','The obese dog','obese.htm')	
		oCMenu.makeMenu('sub415','sub41','Addisons disease','addison.htm')	
		oCMenu.makeMenu('sub416','sub41','Common Canine Poisons','poison.htm','','','40')	
		oCMenu.makeMenu('sub417','sub41','Chocolate poisoning','choc.htm')	
		oCMenu.makeMenu('sub418','sub41','Stress related problems','stress.htm','','','40')	
		oCMenu.makeMenu('sub419','sub41','To vaccinate or not','vacc.htm')			
	
	oCMenu.makeMenu('sub42','top4','Love is not enough','love.htm')
	oCMenu.makeMenu('sub43','top4','Behavioural issues','behaviours.htm')
	
oCMenu.makeMenu('top5','','Rehomed danes','rehomed.htm')

oCMenu.makeMenu('top6','','Gift in a Dane','gift_in.htm')

oCMenu.makeMenu('top7','','GDAS Events','events.htm')

oCMenu.makeMenu('top8','','Ask a question','ask.htm')

oCMenu.makeMenu('top9','','Contact us','contact.htm')

oCMenu.makeMenu('top10','','Links','links.htm')

oCMenu.makeMenu('top11','','Our privacy policy','info/privacy.htm')





	
//Leave this line - it constructs the menu
oCMenu.construct()		
