function mypopup(imgurl, ptitle, width, height) {
	var attributes = "menubar=0, resizeable=1, scrollbars=1, width=";
	width = width + 150;
	height = height + 120;
	
	if (width < 480) {
		width = 480;
	}
	else if (width > 900) {
		width = 900;
	}
	
	if (height < 500) {
		height = 500;
	}
	else if (height > 700) {
		height = 700;
	}
	
	attributes = attributes + width;
	attributes = attributes + ", height=";
	attributes = attributes + height;
	
   	mywindow = window.open ("/samples/show.php?purl=" + imgurl + "&ptitle=" + ptitle, "",attributes);
} 
