/*
Script: Image Rollovers

Created on: April 12/2000
Created by; Chris Jones(chris@nkaos.com) & Paul Kalupnieks(paulk@nkaos.com).

Description: Changes the source of a given image to an on state and then back again.
			 The functions accept one parameted, the numeric value of that image in
			 the refname array.
			 
Compatibility: Javascript 1.0, Netscape 3.0+, Internet Explorer 4.0+
*/

var itsgood 	= document.images;
var refname 	= new Array(); //defines the name attribute
var off 		= new Array(); // defines an array for off iamges
var on 			= new Array(); // edfines an array for on images
var imagePath 	= pathMod + "images/nav/"; // this points to the directory where your nav images are

/* 
The refname array is used to build the on and off arrays.
For every image that will be a rollover, the has to be a name value in the tag.. like so
<img src="../images/howto.gif" width=119 height=25 border=0 alt="" NAME="howto">

To make the script more usable make all of the rollover images use this format
offimage = howto.gif
onimage  = howto_ov.gif

and give the image name value 'howto'
*/
refname[0] = "red";
refname[1] = "pva";
refname[2] = "reliable";
refname[3] = "about";
refname[4] = "technology";
refname[5] = "divisions";
refname[6] = "news";
refname[7] = "contact";
refname[8] = "mailing";

for(j=0;j<refname.length;j++)
{
	if (itsgood){ 
		off[j] 		= new Image();
		off[j].src 	= imagePath + refname[j] + '.gif';
		on[j] 		= new Image();
		on[j].src 	= imagePath + refname[j] + '_ov.gif';
	}
}

// these are the functions that actually execute the the rollovers
// msover is for the oMouseover event, and msout is for the onMouseout event

function msover(number) {
	if (itsgood) {
		var name=refname[number];
		document.images[name].src = on[number].src;
	}
}
		
function msout(number) {
	if (itsgood) {
		var name=refname[number];
		document.images[name].src = off[number].src;
	}
}
//<a href="#.html" onFocus="this.blur();" onMouseover="msover('0');" onMouseout="msout('0');">Image</a>


// these are for the subNav
function subNavOver(name) {
	if (itsgood){
		document.images[name].src = pathMod + "images/nav/arrow_ov.gif";
	}
}

function subNavOut(name) {
	if (itsgood){
		document.images[name].src = pathMod + "images/nav/arrow.gif";
	}
}
//<a href="#.html" target="product" onFocus="this.blur();" onMouseover="subNavOver('arrow1');" onMouseout="subNavOut('arrow1');">BOOTS</a>