
/* Popup of large image in it's own window with a close button.
   Adapted from a tutorial at http://www.htmlgoodies.com/beyond/openwin.html */
function popupimage(img, title, description)
{

	var s1 = "<html>\n<head>\n<title>Waipiata Hotel: Gallery - " + title + "</title>\n</head>\n";
	var s2 = "<body>\n<center>\n<img src='" + img + "' border=0>\n";
	var s3 = "<p>\n" + description + "</p>\n";
	var s4 = "<form>\n<input type='button' value='Close Window'" + " onClick='self.close()'>\n</form>\n";
	var s5 = "</center>\n</body>\n</html>";

	ImageWindow = window.open('', '', config='width=800, height=600, toolbar=no, scrollbars=yes, menubar=no, left=0, top=0');
	ImageWindow.document.write(s1 + s2 + s3 + s4 + s5);
	ImageWindow.document.close();
}
