
// <!-- Hide script from old browsers
// Creation of image objects
if (document.images) 
{
	logoOn=new Image(392, 65);
	logoOn.src="http://www.atlas-inspection.com/graphics/atlaslogo-long-550x95.gif";

	logoOff=new Image(392, 65);
	logoOff.src="http://www.atlas-inspection.com/graphics/atlaslogo-long-550x95.gif";
	
	contactUsOn=new Image(84, 19);
	contactUsOn.src="http://www.atlas-inspection.com/graphics/contact-on.gif";

	contactUsOff=new Image(84, 19);
	contactUsOff.src="http://www.atlas-inspection.com/graphics/contact-off.gif";
	
	rental_imgOn=new Image(108, 14);
	rental_imgOn.src="http://www.atlas-inspection.com/graphics/nav-rental-on.gif";

	rental_imgOff=new Image(108, 14);
	rental_imgOff.src="http://www.atlas-inspection.com/graphics/nav-rental-off.gif";
	
	preOwned_imgOn=new Image(136, 14);
	preOwned_imgOn.src="http://www.atlas-inspection.com/graphics/nav-preOwned-on.gif";

	preOwned_imgOff=new Image(136, 14);
	preOwned_imgOff.src="http://www.atlas-inspection.com/graphics/nav-preOwned-off.gif";
	
	repair_imgOn=new Image(40, 14);
	repair_imgOn.src="http://www.atlas-inspection.com/graphics/nav-repair-on.gif";

	repair_imgOff=new Image(40, 14);
	repair_imgOff.src="http://www.atlas-inspection.com/graphics/nav-repair-off.gif";
	
	service_imgOn=new Image(94, 14);
	service_imgOn.src="http://www.atlas-inspection.com/graphics/nav-service-on.gif";

	service_imgOff=new Image(94, 14);
	service_imgOff.src="http://www.atlas-inspection.com/graphics/nav-service-off.gif";
	
	keyApps_imgOn=new Image(102, 14);
	keyApps_imgOn.src="http://www.atlas-inspection.com/graphics/nav-keyApps-on.gif";

	keyApps_imgOff=new Image(102, 14);
	keyApps_imgOff.src="http://www.atlas-inspection.com/graphics/nav-keyApps-off.gif";
	
	weBuy_imgOn=new Image(47, 14);
	weBuy_imgOn.src="http://www.atlas-inspection.com/graphics/nav-weBuy-on.gif";

	weBuy_imgOff=new Image(47, 14);
	weBuy_imgOff.src="http://www.atlas-inspection.com/graphics/nav-weBuy-off.gif";
}

function on(pic)
{
	if(document.images)
	{
	document.images[pic].src=eval(pic+"On.src");
	}
}

function off(pic)
{
	if(document.images)
	{
	document.images[pic].src=eval(pic+"Off.src");
	}
}

function reDo() { 
	window.location.reload();  
	} 
	window.onresize = reDo; 
	//Define global variables 
	var timerID = null; 
	var timerOn = false; 
	var timecount = 850; 
	// Change this to the time delay that you desire 
	var what = null; 
	var newbrowser = true; 
	var check = false; 
 
function init() {  
	if (document.layers) {  
		layerRef="document.layers";  
		styleSwitch="";  
		visibleVar="show"; 
		what ="ns4";  
		}  
	else if(document.all) {  
		layerRef="document.all";  
		styleSwitch=".style";  
		visibleVar="visible"; 
		what ="ie4";  
		}  
	else if(document.getElementById) {  
		layerRef="document.getElementByID";  
		styleSwitch=".style";  
		visibleVar="visible";  
		what="dom1";  
		}  
	else {  
		what="none";  
		newbrowser = false;  
		} 
	check = true; 
	} 
 
// Toggles the layer visibility on 
function showLayer(layerName) {  
	if(check) {  
		if (what =="none") {  
			return;  
			}  
		else if (what == "dom1") {  
			document.getElementById(layerName).style.visibility="visible";  
			}  
		else {  
			eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.visibility="visible"');  
			}  
		}  
	else {  
		return;  
		}  
	} 
	
// Toggles the layer visibility off 
function hideLayer(layerName) {  
	if(check) {  
		if (what =="none") {  
			return;  
			}  
		else if (what == "dom1") {  
			document.getElementById(layerName).style.visibility="hidden";  
			}  
		else {  
			eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.visibility="hidden"');  
			}  
		}  
	else {  
		return;  
		}  
	} 
	
function hideAll() {  
	hideLayer('menu1');
	hideLayer('menu2');
	hideLayer('menu3');
	hideLayer('menu4');
	hideLayer('menu5');
	hideLayer('menu6');
	hideLayer('menu7');
//Put all layers used in the nav here.  
//Copy the hideLayer() function above.  
	}
	
function startTime() {  
	if (timerOn == false) {  
		timerID=setTimeout( "hideAll()" , timecount);  
		timerOn = true;  
		} 
	} 
 
 function stopTime() {  
 	if (timerOn) {  
		clearTimeout(timerID);  
		timerID = null;  
		timerOn = false;  
		}  
	}
	
function onLoad() {  
	init();  
	}  
// End hiding script from old browsers -->
 

 
 
