newWindow = null;
function ShowWindow(url, width, height)
{
	if (window.screen) 
	{
		scrWidth = screen.availWidth;
		scrHeight = screen.availHeight;
	} 
	else 
	{
		scrWidth = 640;
		scrHeight = 480;
	}

	if (newWindow == null || newWindow.closed) 
	{
		wndParams =
			  "left=" + (scrWidth - width)/2 + ","
			+ "top=" + (scrHeight - height)/2 + ","
			+ "screenX=" + (scrWidth - width)/2 + ","
			+ "screenY=" + (scrHeight - height)/2 + ","
			+ "width=" + width + ","
			+ "height=" + height + ","
			+ "innerWidth=" + width + ","
			+ "innerHeight=" + height + ","
			+ "toolbar=no,"
			+ "location=no,"
			+ "directories=no,"
			+ "status=yes,"
			+ "menubar=no,"
			+ "scrollbars=no,"
			+ "resizable=no";
		
		newWindow = window.open("", "ModalChild", wndParams);
	}

	newWindow.document.open();
	newWindow.document.clear();
  
	newWindow.document.write(
		  '<html>'
		+ '<head>'
		+ '</head>'
		+ '<body style="margin:0px; height:100%; overflow:hidden;">'
		+ '<a href="javascript:window.close()"><img src="'+ url +'" width="' + width + '" height="' + height + '" border="0"></a>'
		+ '</body>'
		+ '</html>'
	);

	newWindow.document.close();
	newWindow.focus();
}

window.onload = function() {
	objects = document.getElementsByTagName("object");
	for (var i = 0; i < objects.length; i++) {
		objects[i].outerHTML = objects[i].outerHTML;
	} //for
}