function siteIn(){
	myDate = new Date();
	inTime = myDate.getTime();
}
function siteOut(){
	myDate = new Date();
	stayTime = Math.floor((myDate.getTime() - inTime)/1000); 
	staySec = stayTime%60 + "sec";
	stayMin = Math.floor(stayTime/60);
	if(stayMin > 0){staySec = stayMin + "min " + staySec;	}
	stayHour = Math.floor(stayTime/3600);
	if(stayHour > 0){staySec = stayHour + "hour " + staySec;	}

	document.mail_form.stay.value = staySec;

	var ref_url;
	if (ref_url = GetCookie("ref_url")){
		document.mail_form.RefUrl.value = ref_url;
	}
}