  if(!((parseInt(navigator.appVersion)<4) && (navigator.appName.toLowerCase().indexOf("microsoft")>-1))) {
  if (parseInt(navigator.appVersion)<3)
    J11=false;
  else
    J11=true;
  }
  else
    J11=false;
	
  var imHeads;

  var swapIm = new Array();
  var old = "";
  var oldSrc = "";
  var old2 = "";
  var oldSrc2 = "";

 var Im= new Array(
 	"/images/level1_lit.gif",
	"/images/level2_lit.gif",
	"/images/level3_lit.gif",
	"/images/level4_lit.gif",
	"/images/level5_lit.gif",
	"/images/level6_lit.gif",
	"/images/level7_lit.gif",
	"/images/level8_lit.gif",
	"/images/level9_lit.gif",
	"/images/level10_lit.gif"
	);

 if(J11) {
   for(i in Im) {
      swapIm[i] = new Image();
	  swapIm[i].src = Im[i];
   }
 }  
   function swap(n,index) {
   if(J11) {
     n = arguments[0].toString();
	 index = parseInt(arguments[1]);
	 eval("oldSrc = document." + n + ".src");
	 old = n;
 
	 eval("document." + n + " .src=swapIm[" + index + "].src");
	 }
   }
   
   function back() {
    if(J11) {
     eval("document." + old + ".src=oldSrc");
    }
   }

/*
<!-- 
the open_window function below is used to open new browser windows, 
used when browsing outside of the Vitesse site.
 -->
 */
function open_window(url) 
{
	window.open(url, "Living",'toolbar=yes,location=1,directories=0,status=0,menubar=no,scrollbars=1,resizable=1,width=640,height=395')
}

function open_Window_b(url) 
{
	popupWin = window.open(url, 'tutorial', 'toolbar=no,location=0,directories=0,status=0,menubar=no,scrollbars=no,resizable=0,width=410,height=590,top=10,left=550')
}

function open_Window_a(url) 
{
	window.open(url, 'feature', 'scrollbars,width=640,height=395,left=10,top=10,toolbar,menubar,status,location,resizable')
}	

function open_infokit()
{
	window.open('infokit.htm', "InfoKit",'toolbar=no,location=0,directories=0,status=0,menubar=no,scrollbars=no,resizable=0,width=357,height=446,top=10,left=550')
}

function modDate()
{
	var months = new Array(13);
	months[1] = "January";
	months[2] = "February";
	months[3] = "March";
	months[4] = "April";
	months[5] = "May";
	months[6] = "June";
	months[7] = "July";
	months[8] = "August";
	months[9] = "September";
	months[10] = "October";
	months[11] = "November";
	months[12] = "December";

	var dateObj = new Date(document.lastModified);
	var lmonth = months[dateObj.getMonth() + 1];
//	alert(lmonth);
	var date = dateObj.getDate();
//	alert(date);
	var fyear = dateObj.getYear();
//	alert(fyear);
	if ((fyear > 50) && (fyear < 150))
	{ 
		fyear = fyear + 1900;
	}
	if (fyear <= 50)
	{
		fyear = fyear + 2000;
	}	
	
	document.write(":: Last Updated :: " + lmonth +" " + date +", " + fyear);
}

function modDate2()
{
	var months = new Array(13);
	months[1] = "January";
	months[2] = "February";
	months[3] = "March";
	months[4] = "April";
	months[5] = "May";
	months[6] = "June";
	months[7] = "July";
	months[8] = "August";
	months[9] = "September";
	months[10] = "October";
	months[11] = "November";
	months[12] = "December";

	var dateObj = new Date(document.lastModified);
	var lmonth = months[dateObj.getMonth() + 1];
//	alert(lmonth);
	var date = dateObj.getDate();
//	alert(date);
	var fyear = dateObj.getYear();
//	alert(fyear);
	if ((fyear > 50) && (fyear < 150))
	{ 
		fyear = fyear + 1900;
	}
	if (fyear <= 50)
	{
		fyear = fyear + 2000;
	}	
	
	document.write(" " + lmonth +" " + date +", " + fyear);
}

function getTimeOfDay()
{
var d = new Date();
var time = '';
var hours = '';
var minutes = '';

hours = d.getHours();

time = time + hours + ':';

minutes = d.getMinutes();
time = time + minutes;

document.write(time);
}

// rollover script

 		function Mid(str, start, len)
         {
                 if (start < 0 || len < 0) return "";
                 var iEnd,iLen;
				 iLen = String(str).length;
                 if (start + len < iLen){
                         iEnd = iLen;}
                 else{iEnd = start + len;}
                 return String(str).substring(start,iEnd);
         }
 
 function preloadimages() {
	 var num = document.images.length;
	 var img,posn,temp,orig,newsrc;
	 var preload = new Array(); 
	 for(var i = 0; i<num; i++) {
	 	img = document.images[i].src;
	 	posn = img.indexOf("nav_");
	 		if(posn > -1){
			 dot = img.lastIndexOf(".");
			 temp = img.substr(dot,img.length);
			 orig = img.substr(0,dot);
			 newsrc = orig + "_lit" + temp;
	 
	 	 preload[i] = new Image();
	     preload[i].src = newsrc;
		 }
 	}
 } 
 function getSrc(n){
    img = n.toString(); 
 	eval("n = document." + img + ".src"); 
 	if(n.indexOf("_lit")< 0){
 		dot = n.lastIndexOf(".");
 		temp = n.substr(dot,n.length).toString();
		orig = n.substr(0,dot).toString();
		newsrc = orig + "_lit" + temp;
	 	newsrc = newsrc.toString();
 	return newsrc;
 	}
	else{return n;}
 }
    function swap(imgname) {
       n = arguments[0].toString();
   		eval("oldSrc = document." + n + ".src");
   		old = n;
  		eval("document." + n + ".src=getSrc('" + imgname + "')");
 }
 function restore(){
      eval("document." + img + ".src=oldSrc");
 
 }
function open_Window_contact(url) 
{
	window.open(url, 'map', 'scrollbars,width=770,height=581,left=10,top=10,toolbar,menubar,status,location,resizable')
}


