
if (top.location != location) top.location.href = location.href;

function picpop(pic,caption){ 
var picpopwin=window.open("picpop.htm?pic=images/photos/"+pic+"&caption="+escape(caption),"picpopwin","top=40,left=40,width=280,height=280,toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0");
}

function getval(strFieldName){
var strFieldValue;
var objRegExp = new RegExp(strFieldName + "=([^&]+)","gi");

if (objRegExp.test(location.search))
strFieldValue = unescape(RegExp.$1);
else strFieldValue="";

return strFieldValue;
}

function fitpic(){
NS = (navigator.appName=="Netscape")?true:false;
iWidth = (NS)?window.innerWidth:document.body.clientWidth;
iHeight = (NS)?window.innerHeight:document.body.clientHeight;
iWidth = document.images[0].width - iWidth;
iHeight = document.images[0].height - iHeight;
window.resizeBy(iWidth+40, iHeight+80);
self.focus();
setTimeout('window.close()',20000);
}

