if (document.images)
   {
   	 nav1on= new Image(149,34);
     nav1on.src="/images/nav3-production-supplies-over.gif";  
     nav1off= new Image(149,34);
     nav1off.src="/images/nav3-production-supplies.gif";
	 
	 nav2on= new Image(117,34);
     nav2on.src="/images/nav3-grip-equipment-over.gif";  
     nav2off= new Image(117,34);
     nav2off.src="/images/nav3-grip-equipment.gif";
	 
	 nav3on= new Image(151,34);
     nav3on.src="/images/nav3-backings-overheads-over.gif";  
     nav3off= new Image(151,34);
     nav3off.src="/images/nav3-backings-overheads.gif";
	 
	 nav4on= new Image(137,34);
     nav4on.src="/images/nav3-lighting-electrical-over.gif";  
     nav4off= new Image(137,34);
     nav4off.src="/images/nav3-lighting-electrical.gif";
	 
	 nav5on= new Image(104,34);
     nav5on.src="/images/nav3-tracks-dollies-over.gif";  
     nav5off= new Image(104,34);
     nav5off.src="/images/nav3-tracks-dollies.gif";
	 
	 nav6on= new Image(110,34);
     nav6on.src="/images/nav3-grip-packages-over.gif";  
     nav6off= new Image(110,34);
     nav6off.src="/images/nav3-grip-packages.gif";
	 
	 nav7on= new Image(97,34);
     nav7on.src="/images/nav3-flags-scrims-over.gif";  
     nav7off= new Image(97,34);
     nav7off.src="/images/nav3-flags-scrims.gif";
	 
	 nav8on= new Image(105,34);
     nav8on.src="/images/nav3-frames-pipes-over.gif";  
     nav8off= new Image(105,34);
     nav8off.src="/images/nav3-frames-pipes.gif";
	 
	 nav9on= new Image(118,26);
     nav9on.src="/images/nav3-expendables-over.gif";  
     nav9off= new Image(118,26);
     nav9off.src="/images/nav3-expendables.gif";
	 
	 nav10on= new Image(118,26);
     nav10on.src="/images/nav3-specials-over.gif";  
     nav10off= new Image(118,26);
     nav10off.src="/images/nav3-specials.gif";
	 
	 nav11on= new Image(224,224);
     nav11on.src="/images/n-production-supplies-over.gif";  
     nav11off= new Image(224,224);
     nav11off.src="/images/n-production-supplies.gif";
	 
	 nav12on= new Image(224,224);
     nav12on.src="/images/n-grip-equipment-over.gif";  
     nav12off= new Image(224,224);
     nav12off.src="/images/n-grip-equipment.gif";
	 
	 nav13on= new Image(224,224);
     nav13on.src="/images/n-backings-overheads-over.gif";  
     nav13off= new Image(224,224);
     nav13off.src="/images/n-backings-overheads.gif";
	 
	 nav14on= new Image(224,224);
     nav14on.src="/images/n-lighting-electrical-over.gif";  
     nav14off= new Image(224,224);
     nav14off.src="/images/n-lighting-electrical.gif";
	 
	 nav15on= new Image(224,224);
     nav15on.src="/images/n-tracks-dollies-over.gif";  
     nav15off= new Image(224,224);
     nav15off.src="/images/n-tracks-dollies.gif";
	 
	 nav16on= new Image(224,224);
     nav16on.src="/images/n-grip-packages-over.gif";  
     nav16off= new Image(224,224);
     nav16off.src="/images/n-grip-packages.gif";
	 
	 nav17on= new Image(224,224);
     nav17on.src="/images/n-flags-scrims-over.gif";  
     nav17off= new Image(224,224);
     nav17off.src="/images/n-flags-scrims.gif";
	 
	 nav18on= new Image(224,224);
     nav18on.src="/images/n-frames-pipes-over.gif";  
     nav18off= new Image(224,224);
     nav18off.src="/images/n-frames-pipes.gif";
	 
   }

function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}

function MM_findObj(n, d) { //v3.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function lightup(imgName)
 {
   if (document.images)
    {
      imgOn=eval(imgName + "on.src");
      document[imgName].src= imgOn;
    }
 }

function turnoff(imgName)
 {
   if (document.images)
    {
      imgOff=eval(imgName + "off.src");
      document[imgName].src= imgOff;
    }
 }
 
 function hideLayer(whichLayer) {

if (document.getElementById) {
// this is the way the standards work
document.getElementById(whichLayer).style.visibility = "hidden";
}
else if (document.all) {
// this is the way old msie versions work
document.all[whichlayer].style.visibility = "hidden";
}
else if (document.layers) {
// this is the way nn4 works
document.layers[whichLayer].visibility = "hidden";
}

}

function showLayer(whichLayer) {

if (document.getElementById) {
// this is the way the standards work
document.getElementById(whichLayer).style.visibility = "visible";
}
else if (document.all) {
// this is the way old msie versions work
document.all[whichlayer].style.visibility = "visible";
}
else if (document.layers) {
// this is the way nn4 works
document.layers[whichLayer].visibility = "visible";
}

}

function handleClick(whichClick,theLayer) {

if (whichClick == "hide it") {
// then the user wants to hide the layer
hideLayer(theLayer);

}
else if (whichClick == "show it") {
// then the user wants to show the layer
showLayer(theLayer);
}

}


function putMessage(error_message){
        alert(error_message);
        return false;   
}

function checkEmail(email){
        var email_string = email.value; 
        var at_position = email_string.indexOf('@'); 
        var dot_position = email_string.indexOf('.', at_position); 
        var extension = email_string.substring(dot_position+1,email_string.length); 
        
        if(at_position<0){
                return false; 
        } else if (dot_position<0){
                return false; 
        } else if (extension.length<=0){
                return false; 
        } 
        return true; 
}

function hasValue(obj, obj_type){
    if (obj_type == "TEXT" || obj_type == "PASSWORD"){
        if (obj.value.length == 0) 
                return false;
        else 
                return true;
    } else if (obj_type == "SINGLE_VALUE_RADIO" || obj_type == "SINGLE_VALUE_CHECKBOX") {
                if (obj.checked)
                        return true;
                else
                return false;   
        } else if (obj_type == "RADIO" || obj_type == "CHECKBOX") {
                for (i=0; i < obj.length; i++){
                        if (obj[i].checked)
                                return true;
                }
                return false;   
        } else  if (obj_type == "SELECT") {
                if (obj.selectedIndex == 0)
                        return false;
                else
                        return true;
        }
}

function hasValue2(obj1, obj2, obj3, obj4, obj5, obj6){
        var flag = 0;
        for (i=1; i < 7; i++){
                if (obj[i].checked)
                        flag = i;
                }
        if (flag == 0)
                return false;
        else
                return true;
}

function  checkFormContact(this_form){
    if  (!hasValue(this_form.firstname, "TEXT" )) {
                if  (!putMessage("Please enter your first name")){
                        return false; 
                }
        }
	if  (!hasValue(this_form.lastname, "TEXT" )) {
                if  (!putMessage("Please enter your last name")){
                        return false; 
                }
        }
	if  (!hasValue(this_form.zip, "TEXT" )) {
                if  (!putMessage("Please enter your zip")){
                        return false; 
                }
        }
    if  (!hasValue(this_form.email, "TEXT" )) {
                if  (!putMessage("Please enter your email address")){
                        return false; 
                }
        } else {
                if (!checkEmail(this_form.email)){
                        if  (!putMessage("Please enter valid email address")){
                                return false; 
                        }
                }
        }
		
	
        
        return true;    
}

function  checkFormContactW(this_form){
    if  (!hasValue(this_form.firstname, "TEXT" )) {
                if  (!putMessage("Please enter your first name")){
                        return false; 
                }
        }
	if  (!hasValue(this_form.lastname, "TEXT" )) {
                if  (!putMessage("Please enter your last name")){
                        return false; 
                }
        }
	if  (!hasValue(this_form.zip, "TEXT" )) {
                if  (!putMessage("Please enter your zip")){
                        return false; 
                }
        }
	if  (!hasValue(this_form.phone, "TEXT" )) {
                if  (!putMessage("Please enter your telephone")){
                        return false; 
                }
        }
    if  (!hasValue(this_form.email, "TEXT" )) {
                if  (!putMessage("Please enter your email address")){
                        return false; 
                }
        } else {
                if (!checkEmail(this_form.email)){
                        if  (!putMessage("Please enter valid email address")){
                                return false; 
                        }
                }
        }
	if  (!hasValue(this_form.sales, "TEXT" )) {
                if  (!putMessage("Please enter your annual sales")){
                        return false; 
                }
        }
	
        
        return true;    
}