function imgOpen( imgPath, imgWidth, imgHeight, imgDescription ) {  // v4.01
  imgW = Math.round(imgWidth) + 45;
  imgH = Math.round(imgHeight) + 200;
  txtW = Math.round(imgWidth) + 14;

  posLeft = (screen.width) ? (screen.width - imgW ) / 2 : 0;
  posTop 	= (screen.height) ? (screen.height - imgH) / 2 : 0;

	newWindow = window.open( "", "newWindow", "width=" + imgW + ",height=" + imgH + ",scrollbars=no,left=" + posLeft + ",top=" + posTop + "" );
  newWindow.document.open();
  newWindow.document.write( '<html><head><title>' + imgDescription + '</title><style type="text/css">@import url("/css/popup.css");</style></head><body>' );
  newWindow.document.write( '<table cellpadding="0" cellspacing="0" width="100%" height="100%">' );
  newWindow.document.write( '<tr><td height="80" align="center"><div class="logo-popup"><img src="/images/logo.gif" alt="" /><!--h1>Nieruchomo¶ci WAM</h1--></div></td></tr>' );
  newWindow.document.write( '<tr><td align="center"><div class="f" style="width:' + imgWidth + 'px;"><img src=\"' + imgPath + '\" alt=\"' + imgDescription + '\" title=\"' + imgDescription + '\" onclick="javascript:window.close();" class="foto" /></div>' );
  if ( imgDescription != '' )newWindow.document.write( '<div class="f" style="width:' + txtW + 'px;margin-top:3px;">' + imgDescription + '</div></td></tr>' );
  newWindow.document.write( '<tr><td>&nbsp;</td></tr>' );
  newWindow.document.write( '<tr><td align="center" height="25" class="zamknij"><a href="javascript:window.close();">[ zamknij ]</a></td></tr>' );
  newWindow.document.write( '</table>' );
  newWindow.document.write( '</body></html>' );
  newWindow.document.close();
}

