var timeoutID;

function SwapInPhoto(imgSrc)
{
	newImgLink = new String(imgSrc);
	newImgLink = newImgLink.replace(/m\.jpg/g, "l.jpg");
	if (timeoutID)
		window.clearTimeout(timeoutID);
	document.images['MainImage'].src = imgSrc;
	document.getElementById('ImageLink').href = newImgLink;
}

function SwapOutPhoto(imgSrc)
{
	if (timeoutID)
		window.clearTimeout(timeoutID);

	newImgLink = new String(imgSrc);
	newImgLink = newImgLink.replace(/m\.jpg/g, "l.jpg");
	var imgString = "document.images['MainImage'].src = \'"+imgSrc+"\'; document.getElementById('ImageLink').href = \'"+newImgLink+"\'";
	timeoutID = window.setTimeout(imgString, 2000);
}

function popUp(URL) 
{
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=400,height=400');");
}
function popUp2(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=520,height=560');");
}
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
