
var menu1=new Array()
menu1[0]='<a href="http://www.hamburgdental.com/index.htm">Introduction</a>'
menu1[1]='<a href="http://www.hamburgdental.com/pages/practiceHistory2.htm">Practice History <br> &nbsp;&nbsp;& philosophy</a>'
menu1[2]='<a href="http://www.hamburgdental.com/pages/implants.htm">A word about dental <br> &nbsp;implants</a>'

//Contents for menu 2, and so on
var menu2=new Array()
menu2[0]='<a href="http://www.hamburgdental.com/pages/officeinfo.htm">Introduction</a>'
menu2[1]='<a href="http://www.hamburgdental.com/pages/contact.htm">Contact Us</a>'
menu2[2]='<a href="http://www.hamburgdental.com/pages/hours.htm">Office Hours</a>'
menu2[3]='<a href="http://www.hamburgdental.com/pages/directions.htm">Directions</a>'
menu2[4]='<a href="http://www.hamburgdental.com/pages/tour.htm">Tour Our Office</a>'
menu2[5]='<a href="http://www.hamburgdental.com/pages/expectations.htm">Expectations</a>'
menu2[6]='<a href="http://www.hamburgdental.com/pages/insurance.htm">Payment Information</a>'
menu2[7]='<a href="http://www.hamburgdental.com/pages/emergencies.htm">Emergencies</a>'
menu2[8]='<a href="http://www.hamburgdental.com/pages/practiceHistory2.htm">Practice History & Philosophy</a>'

var menu3=new Array()
menu3[0]='<a href="#">Health history</a>'
menu3[1]='<a href="#">office procedures & policies</a>'
menu3[2]='<a href="#">hippa</a>'
menu3[3]='<a href="#">teeth whitening</a>'

//---------------------------cosmetic----------------------------------------

var menu5=new Array()
menu5[0]='<a href="http://www.hamburgdental.com/pages/cosmetics.htm">Introduction</a>'
menu5[1]='<a href="http://www.hamburgdental.com/pages/allCeramic.htm">All Ceramic <br> &nbsp;Porcelain Crowns</a>'
menu5[2]='<a href="http://www.hamburgdental.com/pages/fullMouth.htm">Full Mouth <br>&nbsp;Rehabilitaion</a>'
menu5[3]='<a href="http://www.hamburgdental.com/pages/whitening.htm">Whitening</a>'
menu5[4]='<a href="http://www.hamburgdental.com/pages/bonding.htm">Bonding</a>'
menu5[5]='<a href="http://www.hamburgdental.com/pages/fillings.htm">White vs. silver fillings</a>'
menu5[6]='<a href="http://www.hamburgdental.com/pages/gallery.htm">Photo Gallery</a>'

//---------------------------implants----------------------------------------

var menu6=new Array()
menu6[0]='<a href="http://www.hamburgdental.com/pages/implantsIntro.htm">Introduction</a>'
menu6[1]='<a href="http://www.hamburgdental.com/pages/training.htm">Dr. Goldberg&#180;s Training</a>'
menu6[2]='<a href="http://www.hamburgdental.com/pages/implantsFAQs.htm">faqs</a>'

//--------------------------other services ---------------------------------

var menu8=new Array()
menu8[0]='<a href="http://www.hamburgdental.com/pages/otherservices.htm">Introduction</a>'
menu8[1]='<a href="http://www.hamburgdental.com/pages/bridges.htm">bridges</a>'
menu8[2]='<a href="http://www.hamburgdental.com/pages/dentures.htm">dentures</a>'
menu8[3]='<a href="http://www.hamburgdental.com/pages/partials.htm">partials</a>'
menu8[4]='<a href="http://www.hamburgdental.com/pages/crowns.htm">crowns</a>'
menu8[5]='<a href="http://www.hamburgdental.com/pages/whitening.htm">bleaching/whitening</a>'
menu8[6]='<a href="http://www.hamburgdental.com/pages/pediatric.htm">pediatrics</a>'
menu8[7]='<a href="http://www.hamburgdental.com/pages/sealants.htm">sealants</a>'
menu8[8]='<a href="http://www.hamburgdental.com/pages/tmj.htm">TMJ/headaches</a>'
menu8[9]='<a href="http://www.hamburgdental.com/pages/digital-xray.htm">Digital X-Ray</a>'


//--------------------------------testimonials----------------------------------

var menu9=new Array()
menu9[0]='<a href="http://www.hamburgdental.com/pages/testimonials.htm">Introduction</a>'
menu9[1]='<a href="http://www.hamburgdental.com/pages/testimonials/testimonials_linda.htm">linda</a>'
menu9[2]='<a href="http://www.hamburgdental.com/pages/testimonials/testimonials_wendie.htm">wendie</a>'
menu9[3]='<a href="http://www.hamburgdental.com/pages/testimonials/testimonials_barbara.htm">barbara</a>'
menu9[4]='<a href="http://www.hamburgdental.com/pages/testimonials/testimonials_rieger.htm">rieger</a>'
menu9[5]='<a href="http://www.hamburgdental.com/pdfs/hamburg_dentist.pdf" target="_blank">one-stop shopping article</a>'
menu9[6]='<a href="http://www.hamburgdental.com/pdfs/NJ_herald.pdf" target="_blank">nj herald article</a>'
menu9[7]='<a href="http://www.hamburgdental.com/pages/bestDentist.htm">best dentist award</a>'


//----------------------------------first visit--------------------------------

var menu10=new Array()
menu10[0]='<a href="http://www.hamburgdental.com/pages/consultations.htm">introduction</a>'
menu10[1]='<a href="http://www.hamburgdental.com/pages/limitedExam.htm">limited exam</a>'
menu10[2]='<a href="http://www.hamburgdental.com/pages/comprehensive.htm">comprehensive exam</a>'
menu10[3]='<a href="http://www.hamburgdental.com/pages/cosmeticConsultation.htm">cosmetic consultation</a>'

//-------------------------------------------------------------------------------
		
var disappeardelay=250  //menu disappear speed onMouseout (in miliseconds)
var horizontaloffset=2 //horizontal offset of menu from default location. (0-5 is a good value)

/////No further editting needed

var ie4=document.all
var ns6=document.getElementById&&!document.all

if (ie4||ns6)
document.write('<div id="dropmenudiv" style="visibility:hidden;width: 160px" onMouseover="clearhidemenu()" onMouseout="dynamichide(event)"></div>')

function getposOffset(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}


function showhide(obj, e, visible, hidden, menuwidth){
if (ie4||ns6)
dropmenuobj.style.left=dropmenuobj.style.top=-500
dropmenuobj.widthobj=dropmenuobj.style
dropmenuobj.widthobj.width=menuwidth
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
obj.visibility=visible
else if (e.type=="click")
obj.visibility=hidden
}

function iecompattest(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function clearbrowseredge(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=ie4 && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
if (windowedge-dropmenuobj.x-obj.offsetWidth < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure+obj.offsetWidth
}
else{
var topedge=ie4 && !window.opera? iecompattest().scrollTop : window.pageYOffset
var windowedge=ie4 && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure){ //move menu up?
edgeoffset=dropmenuobj.contentmeasure-obj.offsetHeight
if ((dropmenuobj.y-topedge)<dropmenuobj.contentmeasure) //up no good either? (position at top of viewable window then)
edgeoffset=dropmenuobj.y
}
}
return edgeoffset
}

function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}


function dropdownmenu(obj, e, menucontents, menuwidth){
if (window.event) event.cancelBubble=true
else if (e.stopPropagation) e.stopPropagation()
clearhidemenu()
dropmenuobj=document.getElementById? document.getElementById("dropmenudiv") : dropmenudiv
populatemenu(menucontents)

if (ie4||ns6){
showhide(dropmenuobj.style, e, "visible", "hidden", menuwidth)
dropmenuobj.x=getposOffset(obj, "left")
dropmenuobj.y=getposOffset(obj, "top")
dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+obj.offsetWidth+horizontaloffset+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+"px"
}

return clickreturnvalue()
}

function clickreturnvalue(){
if (ie4||ns6) return false
else return true
}

function contains_ns6(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
}

function dynamichide(e){
if (ie4&&!dropmenuobj.contains(e.toElement))
delayhidemenu()
else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
delayhidemenu()
}

function hidemenu(e){
if (typeof dropmenuobj!="undefined"){
if (ie4||ns6)
dropmenuobj.style.visibility="hidden"
}
}

function delayhidemenu(){
if (ie4||ns6)
delayhide=setTimeout("hidemenu()",disappeardelay)
}

function clearhidemenu(){
if (typeof delayhide!="undefined")
clearTimeout(delayhide)
}


