var pushval = 0
var upval = 0
var time = new Date();
var year = time.getYear();

if (year < 2000) {
year = year + 1900;
}

//Contents for menu 0 //New Vehicles
var menu0=new Array()

//Contents for menu 1 //Used Vehicles
var menu1=new Array()
menu1[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/usedinventory.asp">Preowned Vehicles</a><br>'
menu1[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/certifiedinventory.asp">Certified Vehicles</a><br>'

//Contents for menu 2 //Specials
var menu2=new Array()

//Contents for menu 3 //About Us
var menu3=new Array()
menu3[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/aboutus.asp">About Us</a><br>'
menu3[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/hours.asp">Hours & Contact</a><br>'
menu3[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/map.asp">Directions</a><br>'
menu3[3]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/employees.asp?ID=10">Team Leaders</a><br>'
menu3[4]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/purchaseprograms.asp">Ford AXZD Plans</a><br>'
menu3[5]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/blackbook.asp">Value Your Trade</a><br>'
menu3[6]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/policies.asp">Privacy Policies</a><br>'
menu3[7]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/contactus.asp">Contact Us</a><br>'

//Contents for menu 4 //Commercial
var menu4=new Array()
menu4[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/commercial.asp">Commercial Department</a><br>'
menu4[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/commercialinventory.asp">Commercial Vehicles</a><br>'
menu4[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/purchaseprograms.asp">Ford AXZD Plans</a><br>'
menu4[3]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/Preferred.asp">Business Preferred</a><br>'
menu4[4]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/contactus.asp?ID=5">Contact Commercial Dept</a><br>'

//Contents for menu 5 //Showroom
var menu5=new Array()
menu5[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/newinventory.asp">New Vehicles</a><br>'
menu5[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/usedinventory.asp">Used Vehicles</a><br>'
menu5[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/certifiedinventory.asp">Certified Vehicles</a><br>'
menu5[3]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/budgetinventory.asp">Budget Vehicles</a><br>'
menu5[4]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/custominventory.asp">Custom Vehicles</a><br>'
menu5[5]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/commercialinventory.asp">Commercial Vehicles</a><br>'
menu5[6]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/purchaseprograms.asp">Ford AXZD Plans</a><br>'
menu5[7]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/blackbook.asp">Value Your Trade</a><br>'
menu5[8]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/sales.asp">Sales Department</a><br>'
menu5[9]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/internet.asp">Internet Department</a><br>'
menu5[10]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ContactUs.asp?ID=2">Contact Sales</a><br>'

//Contents for menu 6 //Finance
var menu6=new Array()
menu6[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/finance.asp">Finance Department</a><br>'
menu6[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/billcurriesecure/app.asp">Bill Currie Credit App</a><br>'
menu6[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/fordcredit.asp">Ford Credit Pre-Approval</a><br>'
menu6[3]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/fordpayment.asp">Ford Payment Estimator</a><br>'
menu6[4]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/purchaseprograms.asp">Ford AXZD Plans</a><br>'
menu6[5]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/blackbook.asp">Value Your Trade</a><br>'
menu6[6]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ContactUs.asp?ID=6">Contact Finance</a><br>'

//Contents for menu 7 //Service
var menu7=new Array()
menu7[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/service.asp">Service Department</a><br>'
menu7[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/servicetour.asp">Photo Tour</a><br>'
menu7[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/serviceapp.asp">Service Appointment</a><br>'
menu7[3]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/Maintenance.asp">Maintenance Schedule</a><br>'
menu7[4]='&nbsp;&nbsp;<a href="http://www.ford.com/owner-services/maintenance-service/recall-information" target="_blank">Recall Notices</a><br>'
menu7[5]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/myford.asp">My Ford Owner Website</a><br>'
menu7[6]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ContactUs.asp?ID=7">Contact Service</a><br>'

//Contents for menu 8 //Parts
var menu8=new Array()
menu8[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/parts.asp">Parts Department</a><br>'
menu8[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/partstour.asp">Photo Tour</a><br>'
menu8[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ContactUs.asp?ID=8">Contact Parts</a><br>'

//Contents for menu 9 //Body Shop
var menu9=new Array()
menu9[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/bodyshop.asp">Body Shop</a><br>'
menu9[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/bodyshoptour.asp">Photo Tour</a><br>'
menu9[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/bodyshopvideos.asp">Body Shop Videos</a><br>'
menu9[3]='&nbsp;&nbsp;<a href="http://www.checkyourvehicle.com/cgi-bin/vkeylist3.cgi?shopid=2422&ekey=XLI" target="_blank">Check Vehicle</a><br>'
menu9[4]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/estimate.asp">e-Estimate</a><br>'
menu9[5]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/goldclass.asp">I-CAR Gold Class</a><br>'
menu9[6]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/certifiedfirstnetwork.asp">Certified First Network</a><br>'
menu9[7]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/warranty.asp">Limited Warranty</a><br>'
menu9[8]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ccrnnews.asp">CCRN News Flash</a><br>'
menu9[9]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/accident.asp">Accident-What Do I Do?</a><br>'
menu9[10]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ceclass.asp">Locate CE Classes</a><br>'
menu9[11]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ContactUs.asp?ID=9">Contact Body Shop</a><br>'

//Contents for menu 10 //Budget Lot
var menu10=new Array()
menu10[0]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/budget.asp">Budget Lot</a><br>'
menu10[1]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/budgetinventory.asp">Budget Vehciles</a><br>'
menu10[2]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/blackbook.asp">Value Your Trade</a><br>'
menu10[3]='&nbsp;&nbsp;<a href="http://' + CoWebsite + '/ContactUs.asp?ID=11">Contact Budget Lot</a><br>'


var menuwidth='175px' //default menu width
var menubgcolor='#ececec'  //menu bgcolor
var disappeardelay=250  //menu disappear speed onMouseout (in miliseconds)
var hidemenu_onclick="yes" //hide menu when user clicks within menu?

/////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:'+menuwidth+';background-color:'+menubgcolor+'" 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
if (menuwidth!=""){
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 < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure-obj.offsetWidth
}
else{
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)
edgeoffset=dropmenuobj.contentmeasure+obj.offsetHeight
}
return edgeoffset
}

function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}


function dropdownmenu(obj, e, menucontents, menuwidth,pval){
pushval=pval
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")+pushval
dropmenuobj.y=getposOffset(obj, "top")
dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"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)
}

if (hidemenu_onclick=="yes")
document.onclick=hidemenu
