<!--
if (document.images) {
arImageSrc = new Array (
//nav preload
//xPath+ "images/contactUp.gif",
//xPath+ "images/contactDwn.gif"
)

arImageList = new Array ();

for (counter in arImageSrc) {
arImageList[counter] = new Image ();
arImageList [counter].src = arImageSrc [counter];
}
};
function rolloverFolder( imname,imgFolder,over ) {
  if (!document.images) {return};
  if (over)
  { document.images[imname].src = imgFolder+imname+"Dwn.gif"; }
  else
  { document.images[imname].src = imgFolder+imname+"Up.gif"; }
}

function rollOver (imname,over) {
        if (!document.images) {return};
        if (over) { 
        document.images [imname].src = imname  + "Dwn.gif";
		}
        else 
        { 
        document.images [imname].src = imname  + "Up.gif";		
        }
}
function rollOverJPG (imname,over) {
        if (!document.images) {return};
        if (over) { 
        document.images [imname].src = xPath+"images/" + imname  + "Dwn.jpg";
		}
        else 
        { 
        document.images [imname].src = xPath+ "images/" + imname  + "Up.jpg";		
        }
}

/* Added screen coordinates (Allen) */
function openWindow(url,x,y,screenX,screenY,top,left) {
mywin = window.open(url,"win",'toolbar=0,location=1,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=' + x + ',height=' + y + ',screenX=' + screenX + ',screenY=' + screenY + ',top=' + top + ',left=' + left);
}

/* Opens PDF within a small window from ../pdf directory (Allen) */
function openPDFwindow(windowname) {
  mywin = window.open(windowname + ".pdf","Product","toolbar=no,location=no,width=660,height=600,directories=no,status=no,scrollbars=yes,resizable=no,menubar=no,screenX=50,screenY=50,top=50,left=50");
  mywin.focus();  
}

function openPrint(url,x,y,screenX,screenY,top,left) {
mywin = window.open(url,"pdf",'toolbar=0,location=0,directories=0,status=0,menubar=1,scrollbars=1,resizable=1,width=' + 750 + ',height=' + 550 + ',screenX=' + screenX + ',screenY=' + screenY + ',top=' + top + ',left=' + left);
mywin.focus();
}

function printPage() {
  if (window.print)
    window.print()
  else
    alert("Sorry, your browser doesn't support this feature.");
}

function closewindow()
{
  window.close();
}

function openWindow2(url,x,y) {
mywin = window.open(url,"win",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=' + x + ',height=' + y + '');
}
function openWindow3(url,x,y) {
mywin = window.open(url,"win",'toolbar=1,location=1,directories=0,status=1,menubar=1,scrollbars=0,resizable=1,width=' + x + ',height=' + y + '');
}
function openWindow4(url,x,y) {
mywin = window.open(url,"win",'toolbar=1,location=1,directories=0,status=1,menubar=1,scrollbars=1,resizable=1,width=' + x + ',height=' + y + '');
}
function openWindow5(url,x,y) {
mywin = window.open(url,"win",'toolbar=1,location=1,directories=0,status=1,menubar=1,scrollbars=1,resizable=1,width=' + x + ',height=' + y + '');
}

function randomImage() {
	today=new Date();
	jran=today.getTime();
	var number = 4;
	//var random_number="";
	var imageNum="";
	var image="";
	var text_color="";
	ia=9301;
	ic=49297;
	im=233280;
	jran = (jran*ia+ic) % im;
	imageNum = Math.ceil( (jran/(im*1.0)) *number);
	//alert('hello');
	return imageNum;
	//random_number = Math.ceil( (jran/(im*1.0)) *number);
}

////////////////////// C O O K I E   C U T T I N G ///////////////////////
// name - name of the cookie
// value - value of the cookie
// [expires] - expiration date of the cookie (defaults to end of current session)
// [path] - path for which the cookie is valid (defaults to path of calling document)
// [domain] - domain for which the cookie is valid (defaults to domain of calling document)
// [secure] - Boolean value indicating if the cookie transmission requires a secure transmission
// * an argument defaults when it is assigned null as a placeholder
// * a null placeholder is not required for trailing omitted arguments
// example) setCookie('Nav1','',null,'/')
function setCookie(name, value, expires, path, domain, secure) {
  var curCookie = name + "=" + escape(value) +
                  ((expires) ? "; expires=" + expires.toGMTString() : "") +
                  ((path) ? "; path=" + path : "") +
                  ((domain) ? "; domain=" + domain : "") +
                  ((secure) ? "; secure" : "");
  document.cookie = curCookie;
}

// name - name of the desired cookie
// * return string containing value of specified cookie or null if cookie does not exist
// example) getCookie('Nav1')
function getCookie(name) {
  var dc = document.cookie;
  var prefix = name + "=";
  var begin = dc.indexOf("; " + prefix);
  if (begin == -1) {
    begin = dc.indexOf(prefix);
    if (begin != 0) return null;
  } else
    begin += 2;
  var end = document.cookie.indexOf(";", begin);
  if (end == -1)
    end = dc.length;
  pattern = /\++/g;  // globally look for 1 or more '+'
  dc = dc.replace(pattern," ");  // replace all '+' with ' '
  return unescape(dc.substring(begin + prefix.length, end));
}

// name - name of the cookie
// [path] - path of the cookie (must be same as path used to create cookie)
// [domain] - domain of the cookie (must be same as domain used to create cookie)
// * path and domain default if assigned null or omitted if no explicit argument proceeds
function deleteCookie(name, path, domain) {
  if (getCookie(name)) {
    document.cookie = name + "=" + 
                      ((path) ? "; path=" + path : "") +
                      ((domain) ? "; domain=" + domain : "") + 
                      "; expires=Fri, 31 Dec 1999";
  }
}

//-->
