// by Wirley Rivas Garcia

PositionX = 0;
PositionY = 0;
defaultWidth  = 600;
defaultHeight = 500;

var AutoClose = false;

if (parseInt(navigator.appVersion.charAt(0))>=4)
{
  var isNN=(navigator.appName=="Netscape")?1:0;
  var isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0; 
  }
  
var optNN='scrollbars=no,width='+defaultWidth+',height='+defaultHeight +',left='+PositionX+',top='+PositionY;
var optIE='scrollbars=no,width=600,height=500,left='+PositionX+',top='+PositionY;

function VerImagen(imageURL)
{
  if (isNN)
     { imgWin=window.open('about:blank','',optNN); }
  if (isIE)
     { imgWin=window.open('about:blank','',optIE); }
	 
  with (imgWin.document)
  {
  writeln('<html><head><title>Cargando...</title>');
  writeln('<style type="text/css">');
  writeln('<!--');
  writeln('body { 	background-color: #181784;');
  writeln('	margin-left: 0px;');
  writeln('	margin-top: 5px;');
  writeln('	margin-right: 0px;');
  writeln('	margin-bottom: 0px; }');
  writeln('a {	font-family: Geneva, Arial, Helvetica, sans-serif;');
  writeln('	font-size: 12px;');
  writeln('	color: #FFFFFF;');
  writeln('	font-weight: bold; }');
  writeln('a:visited { 	color: #FFFFFF;');
  writeln('	text-decoration: none; }');
  writeln('a:hover { 	color: #FF9900;');
  writeln('	text-decoration: underline; }');
  writeln('a:active { 	color: #FFFFFF;');
  writeln('	text-decoration: none; }');
  writeln('a:link { 	text-decoration: none;}');
  writeln('-->');
  writeln('</style>'); 
  writeln('<sc'+'ript>');
  writeln('var isNN,isIE;');
  writeln('if (parseInt(navigator.appVersion.charAt(0))>=4){');
  writeln('isNN=(navigator.appName=="Netscape")?1:0;');
  writeln('isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}');

  writeln('function reSizeToImage(){');
  
  writeln('if (isIE){');
  writeln('window.resizeTo(10,10);');
  writeln('width=24+100-(document.body.clientWidth-document.images[0].width);');
  writeln('height=32+100-(document.body.clientHeight-document.images[0].height);'); 
  writeln('window.resizeTo(width,height); ');  
  writeln('var ah = screen.availHeight - 30;');
  writeln('var aw = screen.availWidth - 10;');
  writeln('var xc = (aw - width) / 2;');
  writeln('var yc = (ah - height) / 2 ; ');
  writeln('window.moveTo( xc  , yc); }');
  
  writeln('if (isNN){');       
  writeln('window.innerWidth=document.images["Wirley"].width;');
  writeln('window.innerHeight=document.images["Wirley"].height;');
  writeln('var ah = screen.availHeight - 30;');
  writeln('var aw = screen.availWidth - 10;');
  writeln('var xc = (aw - width) / 2;');
  writeln('var yc = (ah - height) / 2 ; ');
  writeln('window.moveTo( xc  , yc); }}');
  
  writeln('function doTitle(){document.title="Intermarine C.A.";}');
  writeln('</sc'+'ript>');
  writeln('</head>');
  writeln('<body scroll="no" onload="reSizeToImage();doTitle();self.focus()">');
  writeln('<table border="0" align="center" cellpadding="0" cellspacing="0">');
  writeln('  <tr>');
  writeln('    <td><div align="center">');
  writeln('      <table border="2" cellpadding="1" cellspacing="0" bordercolor="#FF9900">');
  writeln('        <tr>');
  writeln('          <td><div align="center"><img name="Wirley" src=' + imageURL + ' style="display:block" ></div></td>');
  writeln('        </tr>');
  writeln('      </table>');
  writeln('    </div></td>');
  writeln('  </tr>');
  writeln('  <tr> ');
  writeln('    <td><div align="center"><a href="javascript:window.close()">Cerrar esta Ventana</a> </div></td>');
  writeln('  </tr>');
  writeln('</table>');
  writeln('</body>');
  writeln('</html>');
  close();		
  }}

