if (!level) {var level = "";}

if (document.images) {            // Active Images
                
<!-- the images below refer to the dark blue reference bar -->
            img1on = new Image();      
            img1on.src = "http://nursing.unc.edu/graphics2/degree2X.jpg"; 
            img2on = new Image(); 
            img2on.src = "http://nursing.unc.edu/graphics2/department2X.jpg";  
            img3on = new Image();
            img3on.src = "http://nursing.unc.edu/graphics2/directory2X.jpg";
            img4on = new Image();
            img4on.src = "http://nursing.unc.edu/graphics2/research2X.jpg";
            img5on = new Image();      
            img5on.src = "http://nursing.unc.edu/graphics2/home2X.jpg"; 
			targeton = new Image();
			
<!-- the images below refer to the dark blue reference bar -->                 
            img1off = new Image(); 
            img1off.src = "http://nursing.unc.edu/graphics2/degree2.jpg"; 
            img2off = new Image();          
            img2off.src = "http://nursing.unc.edu/graphics2/department2.jpg"; 
            img3off = new Image();
            img3off.src = "http://nursing.unc.edu/graphics2/directory2.jpg";
            img4off = new Image();
            img4off.src = "http://nursing.unc.edu/graphics2/research2.jpg";
			img5off = new Image(); 
            img5off.src = "http://nursing.unc.edu/graphics2/home2.jpg"; 
			targetoff = new Image();
        }

function pdfWindow(flnm) {
		urlstrg = "pdf/prog-info/" + flnm;
        pdf = window.open(urlstrg ,"pdf_window");
		window.pdf.focus();	
        }


function lastRevised() {
	var week=new Array('Sun','Mon','Tues','Wed','Thurs','Fri','Sat');
	var month=new Array('Jan','Feb','March','April','May','June','July','Aug','Sept','Oct','Nov','Dec');
	dt=new Date(document.lastModified);
	lm_year=dt.getYear();
	// fix for using deprecated getYear() function
	// if getYear() returns less than 4 digit year -- which happens in both older versions of
	// IE and Navigator check to see if less than 70
	// if yes add 2000 because dealing with 2 digit date
	// if no add 1900 because dealing with one of Navigator's post-2000 3 digit year dates
	lm_year=((lm_year<1000)?((lm_year<70)?2000:1900):0)+lm_year;
	lm_month=month[(dt.getMonth())];
	lm_day=week[(dt.getDay())];
	lm_date=dt.getDate();
	daynow = lm_day + " " + lm_month + " " + lm_date + ", " + lm_year;
	return daynow;
}

//direcectory target image function

function getTargetOn () {
	//imgName = new String();
	imgName = document.images["target"].src;
	targetoff.src = imgName;
	
	// parse sting, return everything except the file extension
	fname = imgName.substring((imgName.lastIndexOf("/")+1),(imgName.length - 4));
	
	//get the extension name
	extensionName = imgName.substring((imgName.length - 4), imgName.length);
	
	imgName = "http://nursing.unc.edu/graphics2/" + fname + "X" + extensionName;
	//return imgName;
	targeton.src = imgName;
	}

function mapwin() {
        theWin = window.open("../map/mapframe.html","entVacWin","HEIGHT=447,WIDTH=300,scrollbars=0,resizable=0,menubar=0,toolbar=0,location=0,directories=0");
}



       
// Function to 'activate' images.
function imgOn(imgName) {
        if (document.images) {
            document[imgName].src = eval(imgName + "on.src");
        }
}


// Function to 'deactivate' images.
function imgOff(imgName) {
        if (document.images) {
            document[imgName].src = eval(imgName + "off.src");
        }
}

// new image swap routines, revised May 2002 for upgraded webpage
function imageRestore() { 
	var i,x,a=document.imgSRC; 
	for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) 
		x.src=x.oSrc;
	}

//creates IMAGE object for each argument in preloadRollOverImages and sets image src
function preloadRollOverImages() {
	var d=document;
	if(d.images){
		if(!d.TMP_rolloverHolder)// if there's no TMP_rolloverHolder array create one
			d.TMP_rolloverHolder=new Array();// serves as holder for preloaded images, never gets accessed directly just allows images to exist in local memory
		var i,j=d.TMP_rolloverHolder.length,a=preloadRollOverImages.arguments; 
		for(i=0; i<a.length; i++) { //loop over the number of arguements passed to preloadRollOverImages()
			d.TMP_rolloverHolder[j]=new Image; //create a new Image object in the MM_p array
			d.TMP_rolloverHolder[j++].src = level + a[i]; // set source property of newly created image and then increment the index number, which is j
			}
		} // END of check for IMAGE array
	}

function findImgObj(n, d) {
	var p,i,x;
	if(!d) d=document; 
	if(!(x=d.images[n])) 
		x=d.images[n];
	return x;
	}

function doRollover() {
	var i,j=0,x,a=doRollover.arguments; // declare variables
	document.imgSRC=new Array; // make a new Array called MM_sr
	for(i=0;i<(a.length-2);i+=4) // loop while the arguments of MM_swapImage
		if ((x=findImgObj(a[i]))!=null) {
			document.imgSRC[j++]=x; // ?? gets the current image object
			
			// swaps out the image
			if(!x.oSrc)
				x.oSrc=x.src;
				x.src= level + a[i+2];}
	}

