// lazy shortcut

d=document;

// window opener scripts

function popmovie(type,which){alert("opens movie "+which);}
function popletter(which){alert("opens letter "+which);}

// show/hide

function show(object) {
if (d.getElementById && d.getElementById(object) != null)
node = d.getElementById(object).style.visibility='visible';
else if (d.layers && d.layers[object] != null)
d.layers[object].visibility = 'visible';
else if (d.all)
d.all[object].style.visibility = 'visible';
}
function hide(object) {
if (d.getElementById && d.getElementById(object) != null)
node = d.getElementById(object).style.visibility='hidden';
else if (d.layers && d.layers[object] != null)
d.layers[object].visibility = 'hidden';
else if (d.all)
d.all[object].style.visibility = 'hidden';
}

// newsletter show/hide for age cookie


function hideall(){
	hide('newstuff');
	hide('newsletter');
	hide('tooyoung');
	hide('thankyou');
}
function homedivs(which){
	hideall();	
	var failtest = GetCookie('notoldenough');
	if ((which=='newsletter')&&(failtest!=null)){
		show('tooyoung');
	}else{
		show(which);
	}
}

// window opener

function popwin(url,name,width,height){
var t=(screen.height-height)/2;
var l=(screen.width-width)/2;
window.open(url,name,'width='+width+',height='+height+',top='+t+',left='+l+',location=0,status=0,scrollbars=0,toolbar=0,resizeable=no,noresize');
}

function popscroll(url,name,width,height){
var t=(screen.height-height)/2;
var l=(screen.width-width)/2;
window.open(url,name,'width='+width+',height='+height+',top='+t+',left='+l+',location=0,status=0,scrollbars=1,toolbar=0,resizeable=no,noresize');
}

function popGame(which,width,height) {
	popwin('pop_game.php?game='+which,'game',width,height);
} // popGame

function popRobot() {
	popwin('pop_robot.php', 'robot', 760, 600);
} // popRobot