function openImageWindow(url)
{
	var width = screen.width - 100;
	var height = screen.height - 150;

	var wnd = window.open('', '', 'location=no,toolbar=no,scrollbars,top=50, left=50,width=400,height=400');
	wnd.document.open();
	wnd.document.write(
		'<html><body leftmargin=0 rightmargin="0" bottommargin="0" topmargin=0 marginheight=0 marginwidth=0 onload="var image = document.getElementById(\'someImage\');window.resizeTo(image.width + 100,image.height + 100);">'+
		'<table width="100%" height="100%" id="someTable"><tr><td align="center" valign="middle" id="imageContainer"><img id="someImage" src="'+url+'"></td></tr></table>'+
		'</body></html>'
	);
	wnd.document.close();

	return false;
}


