function centered_popup(URL, wwidth, wheight)
{
	image_popup(URL, wwidth, wheight);
}
function show_popup(URL, wname, wwidth, wheight)
{
	var wleft = (screen.width-wwidth)/2;
	var wtop = (screen.height-wheight)/2;
	window.open(URL, wname, 
		'toolbar=no,location=no,titlebar=yes,status=yes,menubar=no,'+
		'resizable=no,copyhistory=no,scrollbars=yes,'+
		'width='+wwidth+',height='+wheight+',top='+wtop+',left='+wleft);
}
function image_popup(URL, wwidth, wheight)
{
	return show_popup(URL, '_blank', wwidth, wheight);
}
function popup_safe(URL, wwidth, wheight)
{
	var day = new Date();
	var id = day.getTime();
	var wleft = (screen.width-wwidth)/2;
	var wtop = (screen.height-wheight)/2;
	eval(	"page" + id + " = window.open("+
		"URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,"+
		"width="+wwidth+",height="+wheight+",left="+wleft+",top="+wtop+"');");
}
function email_show( aid, email )
{
	aobj = document.getElementById(aid);
	aobj.href = 'mailto:'+email;
	aobj.innerHTML = email;
}
function toggle(clicked)
{
	if (clicked.style.display == "none")
		clicked.style.display = "inline";
	else
		clicked.style.display = "none";
}
function switch_language(name)
{
	document.switchlanguage.language.value = name;
	document.switchlanguage.submit();
}