function heardImg(imgurl, win, width, height, restitle, caption, catalogue)
{
	horz = width + 28;
	vert = height + 100;
	imgwin = window.open('', win, 'resizable=no,toolbar=no,menubar=no,width=' + horz + ',height=' + vert);
	imgwin.document.writeln('<html><head><title>' + restitle + '</title><meta http-equiv="imagetoolbar" content="no"><link rel="stylesheet" href="/style.css" type="text/css"></head>');
	imgwin.document.writeln('<body bgcolor="#ffffff" text="#000000">');
	imgwin.document.writeln('<table border="0" cellpadding="0" cellspacing="0" width="100%" height="100%">');
	imgwin.document.writeln('<tr>');
	imgwin.document.writeln('<td colspan="3" width="100%"><img src="/images/spacer.gif" alt="" width="1" height="1" border="0"></td>');
	imgwin.document.writeln('</tr>');
	imgwin.document.writeln('<tr>');
	imgwin.document.writeln('<td width="50%" valign="middle"><img src="/images/spacer.gif" alt="" width="1" height="1" border="0"></td>');
	imgwin.document.writeln('<td align="left" valign="middle">');
	imgwin.document.writeln('<img src="' + imgurl + '" alt="' + restitle + '" width="' + width + '" height="' + height + '" border="0"><br>');
	imgwin.document.writeln('<table border="0" cellpadding="5" cellspacing="0" width="100%">');
	imgwin.document.writeln('<tr>');
	imgwin.document.writeln('<td align="left" valign="top" background="/images/popupTitleBacking.jpg"><img src="/images/spacer.gif" alt="" width="5" height="1" border="0"><b>' + catalogue + '</b></td>');
	imgwin.document.writeln('</tr>');
	imgwin.document.writeln('</table>');
	imgwin.document.writeln('<br>');
/*	imgwin.document.writeln('<img src="/images/spacer.gif" alt="" width="10" height="1" border="0"><b>Dimensions:</b> ' + width + ' &times; ' + height + '<br>'); */
	imgwin.document.writeln('<img src="/images/spacer.gif" alt="" width="10" height="1" border="0">' + caption + '<br>');
	imgwin.document.writeln('</td>');
	imgwin.document.writeln('<td width="50%" valign="middle"><img src="/images/spacer.gif" alt="" width="1" height="1" border="0"></td>');
	imgwin.document.writeln('</tr>');
	imgwin.document.writeln('<tr>');
	imgwin.document.writeln('<td colspan="3" width="100%"><img src="/images/spacer.gif" alt="" width="1" height="1" border="0"></td>');
	imgwin.document.writeln('</tr>');
	imgwin.document.writeln('</table>');
	imgwin.document.writeln('<div class="popupnav" style="margin:12px;width:100px;margin-right:0;"><a href="javascript:window.parent.close();" style="font:bold 8pt Verdana,Arial,Helvetica,sans-serif;">CLOSE</a></div><div style="height:60px"></div></div>');
	imgwin.document.writeln('</body></html>');
	imgwin.document.close();
	if (window.focus) { imgwin.focus(); }
}

// Function to display images in a popup window
// WJMB 2003-12
function imgWindow(imgurl, win, width, height, restitle, caption, catalogue) {
	horz = width + 28;
	vert = height + 100;
	imgwin = window.open('', win, 'resizable=no,toolbar=no,menubar=no,width=' + horz + ',height=' + vert);
	imgwin.document.writeln('<html><head><title>' + restitle + '</title><meta http-equiv="imagetoolbar" content="no"></head>');
	imgwin.document.writeln('<body bgcolor="#f2f8ff" text="#000000">');
	imgwin.document.writeln('<div align="center"><img src="' + imgurl + '" width="' + width + '" height="' + height + '" border="1" alt="' + restitle + '"><div class="caption" style="font:10pt Verdana,Arial,Helvetica,sans-serif;">' + caption + '</div>');
	if (catalogue != undefined && catalogue != '') {
		imgwin.document.writeln('<div style="font:10pt Verdana,Arial,Helvetica,sans-serif;color:#999">' + catalogue + '</div>');
	}
	imgwin.document.writeln('<div class="popupnav" style="margin:12px;width:100px;margin-right:0;"><a href="javascript:window.parent.close();" style="font:bold 8pt Verdana,Arial,Helvetica,sans-serif;">CLOSE</a></div><div style="height:60px"></div></div>');
	imgwin.document.writeln('</body></html>');
	imgwin.document.close();
	if (window.focus) { imgwin.focus(); }
}
// WJMB 2009-08
function mobile_version(mobile_url) {
	var url = window.location.toString();
	var a = navigator.userAgent.toLowerCase();
	if (url.indexOf("full=1") == -1 && (a.indexOf("iphone") >= 0 || a.indexOf("ipod") >= 0 || a.indexOf("blackberry") >= 0 
		|| a.indexOf("nokia") >= 0 || a.indexOf("android") >= 0 || a.indexOf("windows ce") >= 0 || a.indexOf("palmos") >= 0
		|| a.indexOf("240x320") >= 0 || a.indexOf("opera mini") >= 0)) {
		window.location = mobile_url;
	}
}