function slidePop(photoid) {
	window.open('/slide.php?photoid=' + photoid,'righthere','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,copyhistory=no,width=400,height=400');
}

function newWindow(url, w, h) {
	window.open(url,"tum"+w,"width="+w+",height="+h+",status=yes,scrollbars=yes,resizable=yes");
}

// This function opens links in an external window in a standards compliant way.
// To use it, code the link like this:
// 		<a href="document.html" rel="external">external link</a>
function externalLinks() {
	if (!document.getElementsByTagName) return;
	var anchors = document.getElementsByTagName("a");
	for (var i=0; i<anchors.length; i++) {
		var anchor = anchors[i];
		if (anchor.getAttribute("href") && anchor.getAttribute("rel") == "external") {
	     	anchor.target = "_blank";
		}
 	}
}
window.onload = externalLinks;

// Set a form target to a new target.  Use this to open a form in a new window, like this:
// <form action="whatever.php" method="post" onsubmit="return setFormTarget(this, '_blank');">
function setFormTarget(formname, new_target) {
	formname.target = new_target;
}