
/***********************************************
* AnyLink Vertical Menu- © Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/





//Contents for Comapny Info 
/*var menu1=new Array()
menu1[0]='<a href="museum.php">Museum</a>'
menu1[1]='<a href="library.php">Library</a>'
menu1[2]='<a href="photoarchives.php">Photo Archives</a>'
menu1[3]='<a href="http://dsf.chesco.org/archives/site/default.asp" target="_blank">Chester County Archives</a>'
menu1[4]='<a href="research.php">Research</a>'*/


//Contents for About Us
var menu2=new Array()
menu2[0]='<a href="company.php"><strong>About The Company</strong></a>'
menu2[1]='<a href="capabilities.php"><strong>Our Capabilities</strong></a>'
menu2[2]='<a href="environment.php"><strong>The Environment</strong></a>'


//Contents for Products 
var menu3=new Array()
menu3[0]='<a href="custom.php"><strong>Custom Timber Systems</strong></a>'
//menu3[1]='<a href="standard.php"><strong>Standard Timber Systems</strong></a>'
menu3[1]='<a href="ligna-span.php"><strong>Ligna-Span Timber Systems</strong></a>'
menu3[2]='<a href="decking.php"><strong>Tongue &amp; Groove Decking</strong></a>'
menu3[3]='<a href="deckpanels.php"><strong>Deck Panels</strong></a>'
menu3[4]='<a href="trusses.php"><strong>Timber Trusses</strong></a>'
menu3[5]='<a href="finishes.php"><strong>Finishes &amp; Treatments</strong></a>'


//Contents for Gallery
var menu4=new Array()
menu4[0]='<a href="civic.html" ><strong>Civic &amp; Educational</strong></a>'
menu4[1]='<a href="corporate.html" ><strong>Corporate</strong></a>'
menu4[2]='<a href="hospitality.html" ><strong>Hospitality</strong></a>'
menu4[3]='<a href="athletic.html" ><strong>Athletic Facilities</strong></a>'
//menu4[4]='<a href="recreational2.html" ><strong>Recreational II</strong></a>'
menu4[4]='<a href="religious.html" ><strong>Religious</strong></a>'
menu4[5]='<a href="residential.html" ><strong>Residential</strong></a>'
menu4[6]='<a href="miscellaneous.html" ><strong>Miscellaneous</strong></a>'

//Contents for News
/*var menu5=new Array()
menu5[0]='<a href="#.php">**Mission</a>'
menu5[1]='<a href="#.php">**Fast Facts</a>'
menu5[2]='<a href="#.php">**Publications</a>'
menu5[3]='<a href="#.php">**What&rsquo;s New?</a>'
menu5[4]='<a href="media.php">Media Relations</a>'
menu5[4]='<a href="media.php">News Releases</a>'
menu5[5]='<a href="facility.php">Facility Rentals</a>'
menu5[6]='<a href="#.php">**Employment Opportunities</a>'
menu5[7]='<a href="contactus.php">Contact Us</a>'*/


//Contents for Contact
/*var menu6=new Array()
menu6[0]='<a href="general.php">Admissions</a>'
menu6[1]='<a href="general.php">Directions and Hours</a>'
menu6[2]='<a href="general.php">Parking</a>'
menu6[3]='<a href="http://www.cchs-store.org">The Museum Store</a>'
menu6[4]='<a href="#.php">**Lodging and Dining</a>'
menu6[5]='<a href="links.php">Area Links</a>'
menu6[6]='<a href="contactus.php">Contact Us</a>'*/



var menuwidth='180px' //default menu width
var menubgcolor='#000'  //menu bgcolor
var disappeardelay=300  //menu disappear speed onMouseout (in miliseconds)
var hidemenu_onclick="yes" //hide menu when user clicks within menu?


/////No further editing 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){
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")+"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

