//this function is to show a popup window
// it takes three arguments :
// src - the path of the image that should be shown
// width - the width of the window, should be ideally equal to the width of the image so that the image fits nicely
// height - the height of the window, should be ideally a bit(17px acc. to current style) bigger than image height so that the
// close button is visible
var objWin, HTMLtxt;
function popup (src, width, height)
{
	if(objWin)
		objWin.close();
		
	objWin = window.open("", "popup", 'width=' + width + ', height=' + (height + 33) + ', resizable=no');
	HTMLtxt = "<html><head><title>PBC Art Gallery</title></head>";
	HTMLtxt = HTMLtxt + "<body style='margin:0px 0px 0px 0px'>"
	HTMLtxt = HTMLtxt + "<img src=" + src + ">";
	HTMLtxt = HTMLtxt + "<div style='background-color:#E5F6FF; font:10px verdana; text-align:center; padding:5px 0px'>";	
	HTMLtxt = HTMLtxt + "<div><b>TITLE</b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Manta Ray Beach</div>"; 
	HTMLtxt = HTMLtxt + "<div><b>ARTIST</b> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:&nbsp;&nbsp;&nbsp;&nbsp;Frida Steinberger</div>";
	HTMLtxt = HTMLtxt + "</div>";
	HTMLtxt = HTMLtxt + "<div style='background-color:#3BB4F4;text-align:right;font:11px verdana;padding:3px 15px 3px 0px'>";
	HTMLtxt = HTMLtxt + "<a href='javascript:window.close()' style='color:#FFFFFF; text-decoration:none'><b>Close this window</b></a></div>";
	HTMLtxt = HTMLtxt + "</body></html>";
	objWin.document.open();
	objWin.document.write(HTMLtxt);
	objWin.document.close();
	objWin.focus();
}

