// preload function
function preload(imageName,imgSrc) {
	if (document.images) {
		eval(imageName+' = new Image()')
		eval(imageName+'.src = "/images/nav/'+ imgSrc +'"')
	}
}

function on(imageName) {
	if (document.images) {
		document[imageName].src = eval(imageName + "On.src");
	}
}

function off(imageName) {
  if (document.images) {
    document[imageName].src = eval(imageName + "Off.src");
  }
}

var newWin = null; 

function popUp(strURL,strType,strHeight,strWidth) { 
	if (newWin != null && !newWin.closed) 
		newWin.close(); 
	var strOptions=""; 
	if (strType=="console") 
		strOptions="resizable,height=" + strHeight + ",width=" + strWidth;
	if (strType=="fixed") 
		strOptions="status,scrollbars=0,height=" + strHeight + ",width=" + strWidth; 
	if (strType=="elastic") 
		strOptions="toolbar,menubar,scrollbars," + "resizable,location,height="+ strHeight + ",width=" + strWidth;
	newWin = window.open(strURL, 'newWin', strOptions); 
	newWin.focus(); 
}

var outWin = null;

function elsewhere(url) {
	if (outWin != null && !outWin.closed)
		outWin.close();
	outWin = window.open(url);
	outWin.focus();
}
