function blockError(){return true};
window.onerror = blockError;

function antyzaz(evt)
        {if(evt.which==1){return false}}

document.onmousedown=antyzaz; 

var NN, IE;

function recognizeBrowser()
        { NN=false;IE=false;
          var str = navigator.userAgent;
          NN = (str.indexOf("Netscape") != -1) ? true : false;
          if(NN)return;
          IE = (str.indexOf("MSIE") != -1) ? true : false;}

function blockMouseIE()
        { if(event.button == 2){return false;}}

function blockMouseNN(evt)
        { if(evt.which == 1){return false;}}

function blockMouseNN2(evt)
        { if(evt.which == 3){return false;}}

recognizeBrowser();
          if(NN){document.captureEvents(Event.MOUSEDOWN); document.onmousedown=blockMouseNN; document.onmouseup=blockMouseNN2;}
          if(IE){document.onmousedown=blockMouseIE;} 

function blockError(){return true;}
window.onerror = blockError;

function blockKeyDownNN(evt)
        { if(evt.which>0){return false}}

function blockKeyDownIE()
        { if(event.keyCode = 17){return false;}}

document.onkeypress=blockKeyDownNN;
if(navigator.userAgent.indexOf("MSIE")!=-1){document.onkeydown=blockKeyDownIE;};

if(frames){if(top.frames.length>0)top.location.href=self.location};

function focus() {
for (a=0;a<document.links.length;)
document.links[a].onfocus=document.links[a++].blur;
}

function displayWindow(str1,str2,str3,str4) {
 var winWidth = (screen.width ) / 2-300;
 var winHeight = (screen.height ) / 2-255;
 var i=0;
 if (navigator.appName == "Netscape") 
   i=40;
 winHeight = 20;
 winprops = 'width=810,height=740,top='+winHeight+',left='+winWidth+',toolbar=0,location=0,directories=0,menubar=0,resizeable=0';
 msg = window.open('','pro_creation_ecard', winprops);
 if (msg.document.images[0])
   msg.close();
 msg = window.open('','pro_creation_ecard', winprops);
 msg.document.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">');
 msg.document.write('<html>');
 msg.document.write('<head>');
 if (str2!=null)
   msg.document.write('<title>'+str2+'</title>');
 else
   msg.document.write('<title>***</title>');
 msg.document.write('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2"> ');
 msg.document.write('<link rel="stylesheet" href="http://www.adwentysci.waw.pl/okno.css" type="text/css">');
 msg.document.write('<SCRIPT LANGUAGE="JavaScript1.2"> function blockError(){return true}; window.onerror = blockError; function antyzaz(evt) {if(evt.which==1){return false}} document.onmousedown=antyzaz; function blockError(){return true;} window.onerror = blockError; function blockKeyDownNN(evt) { if(evt.which>0){return false}} function blockKeyDownIE() { if(event.keyCode = 17){return false;}} document.onkeypress=blockKeyDownNN; if(navigator.userAgent.indexOf("MSIE")!=-1){document.onkeydown=blockKeyDownIE;}; </SCRIPT>');
msg.document.write('</head>');
 msg.document.write('<body onselectstart="return false" oncopy="return false" onLoad="menubar.visible=false" onUnLoad="menubar.visible=true" bgcolor="white" text="#7A90BC">');
 msg.document.write('<p align="center" >');
 msg.document.write('<img src="'+str1+'" style="BORDER-LEFT: #ffffff 2px solid; BORDER-RIGHT: #ffffff 2px solid; BORDER-TOP: #ffffff 2px solid; BORDER-BOTTOM: #ffffff 2px solid; cursor: hand" title="kliknij, aby zamkn±æ" onclick="window.close()" onselectstart="return false" oncontextmenu="return false" oncopy="return false" onLoad="menubar.visible=false" onUnLoad="menubar.visible=true" >');
 msg.document.write('</p>');
 if (str4!=null)
   {
    msg.document.write('<p align="justify">'+str4+'</p>');
    i = i-40;    
   };
 if (str3!=null)
   {
    msg.document.write('<p align="center"><a href="javascript:window.close()">'+str3+'</a></p>');
    i = i-40;    
   };
 msg.document.write('</body>');
 msg.document.write('</html>');
 if (0 & msg.document.images[0])
  {
   winWidth  = msg.document.images[0].width +30;
   winHeight = msg.document.images[0].height+60-i;
   msg.window.resizeTo(winWidth, winHeight);
   msg.window.moveTo((screen.width-winWidth)/2,(screen.height-winHeight)/2);
  };
 msg.focus();
}

