
// Set the URL so the rollovers and drop-downs work from any directory
var siteURL = "http://www.hederman.com/";

	
// Rollovers
// ---------

if (document.images) {
	companyinfoOn = new Image
	companyinfoOn.src = siteURL + "images/b_companyinfo_on.gif"
	companyinfoOff = new Image
	companyinfoOff.src = siteURL + "images/b_companyinfo_off.gif"

	productsOn = new Image
	productsOn.src = siteURL + "images/b_products_on.gif"
	productsOff = new Image
	productsOff.src = siteURL + "images/b_products_off.gif"

	resourcesOn = new Image
	resourcesOn.src = siteURL + "images/b_resources_on.gif"
	resourcesOff = new Image
	resourcesOff.src = siteURL + "images/b_resources_off.gif"
	
	customerserviceOn = new Image
	customerserviceOn.src = siteURL + "images/b_customerservice_on.gif"
	customerserviceOff = new Image
	customerserviceOff.src = siteURL + "images/b_customerservice_off.gif"
	
	joboppsOn = new Image
	joboppsOn.src = siteURL + "images/b_jobopps_on.gif"
	joboppsOff = new Image
	joboppsOff.src = siteURL + "images/b_jobopps_off.gif"
	
	contactOn = new Image
	contactOn.src = siteURL + "images/b_contact_on.gif"
	contactOff = new Image
	contactOff.src = siteURL + "images/b_contact_off.gif"
}
else {
	companyinfoOn = ""
	companyinfoOff = ""
	document.companyinfo = ""
	
	productsOn = ""
	productsOff = ""
	document.products = ""
	
	resourcesOn = ""
	resourcesOff = ""
	document.resources = ""
	
	customerserviceOn = ""
	customerserviceOff = ""
	document.customerservice = ""
	
	joboppsOn = ""
	joboppsOff = ""
	document.jobopps = ""
	
	contactOn = ""
	contactOff = ""
	document.contact = ""
}

function buttonOn(imgName) {
	document[imgName].src = eval(imgName + "On.src")
}

function buttonOff(imgName) {
	document[imgName].src = eval(imgName + "Off.src")
}


// Drop-down menu and rollovers
// ----------------------------

function writemenu() {
	// If the browser qualifies, write the menus into the page
	if (document.getElementById) {
		// Company Info menu
		document.write ('<div id="dropDownMenu1" onmouseover="showmenu(\'companyinfo\',\'dropDownMenu1\')" onmouseout="hidemenu(\'companyinfo\',\'dropDownMenu1\')">');
		document.write ('<a href="' + siteURL + 'companyinfo/history.html">History</a>');
		document.write ('<a href="' + siteURL + 'companyinfo/iso.html">ISO Certification</a>');
		document.write ('<a href="' + siteURL + 'companyinfo/fsc.html">FSC Supplier</a>');
		document.write ('<a href="' + siteURL + 'companyinfo/capabilities.html">Capabilities</a>');
		document.write ('<a href="' + siteURL + 'companyinfo/departments.html">Departments</a>');
		document.write ('<a href="' + siteURL + 'companyinfo/location.html">Location/Hours</a>');
		document.write ('</div>');
		// Resources and Support menu
		document.write ('<div id="dropDownMenu2" onmouseover="showmenu(\'resources\',\'dropDownMenu2\')" onmouseout="hidemenu(\'resources\',\'dropDownMenu2\')">');
		document.write ('<a href="' + siteURL + 'resources/glossary.html">Glossary of Terms</a>');
		document.write ('<a href="' + siteURL + 'resources/faqs.html">FAQs</a>');
		document.write ('<a href="' + siteURL + 'resources/software.html">Downloads</a>');
		document.write ('<a href="' + siteURL + 'resources/tips.html">Tips &amp; Tricks</a>');
		document.write ('<a href="' + siteURL + 'resources/specs.html">File Submission Specs</a>');
		document.write ('</div>');
		// Customer Service menu
		document.write ('<div id="dropDownMenu3" onmouseover="showmenu(\'customerservice\',\'dropDownMenu3\')" onmouseout="hidemenu(\'customerservice\',\'dropDownMenu3\')">');
		document.write ('<a href="' + siteURL + 'customerservice/sales.html">Sales Department</a>');
		document.write ('<a href="' + siteURL + 'customerservice/csreps.html">Customer Service Reps.</a>');
		document.write ('<a href="' + siteURL + 'customerservice/design.html">Design Dept.</a>');
		document.write ('<a href="' + siteURL + 'customerservice/prepress.html">Prepress Dept.</a>');
		document.write ('<a href="' + siteURL + 'customerservice/press.html">Press &amp; Bindery</a>');
		document.write ('<a href="' + siteURL + 'customerservice/management.html">Management Team</a>');
		document.write ('</div>');
		// Job Opportunities menu
		document.write ('<div id="dropDownMenu4" onmouseover="showmenu(\'jobopps\',\'dropDownMenu4\')" onmouseout="hidemenu(\'jobopps\',\'dropDownMenu4\')">');
		document.write ('<a href="' + siteURL + 'jobopps/openings.html">Current Openings</a>');
		document.write ('<a href="' + siteURL + 'jobopps/benefits.html">Benefits</a>');
		document.write ('</div>');
	}
}

function showmenu(whichButton, whichMenu) {
	// turn on button hilite
	document[whichButton].src = eval(whichButton + "On.src");
	// show drop-down menu
	if (document.getElementById) {
		var obj = document.getElementById(whichMenu);
		obj.style.visibility = "visible";
	}
}

function hidemenu(whichButton, whichMenu) {
	// turn off button hilite
	document[whichButton].src = eval(whichButton + "Off.src");
	// show drop-down menu
	if (document.getElementById) {
		var obj = document.getElementById(whichMenu);
		obj.style.visibility = "hidden";
	}
}