﻿window.status = "VOJSKO.NET"





/* OKNO OBRÁZKU */
function show(anch)	{
	return popImage(anch.href,"");
}
function popImage( imageURL,imageTitle,width,height ){
	var AutoClose = true;
	var PositionX = 0;
	var PositionY = 0;
	var defaultWidth  = 800;
	var defaultHeight = 600;
	var imgWin = window.open('','_blank','scrollbars=no,resizable=no,width='+defaultWidth+',height='+defaultHeight+',left='+PositionX+',top='+PositionY);

	if( !imgWin ) { return true; } //popup blockers should not cause errors
	imgWin.document.write('<html><head><title>'+imageTitle+'<\/title><script type="text\/javascript">\n'+
		'function resizeWinTo() {\n'+
		'if( !document.images.length ) { document.images[0] = document.layers[0].images[0]; }'+
		'var oH = document.images[0].height, oW = document.images[0].width;\n'+
		'if( !oH || window.doneAlready ) { return; }\n'+ //in case images are disabled
		'window.doneAlready = true;\n'+ //for Safari and Opera
		'var x = window; x.resizeTo( oW + 100, oH + 100 );\n'+
		'var myW = 0, myH = 0, d = x.document.documentElement, b = x.document.body;\n'+
		'if( x.innerWidth ) { myW = x.innerWidth; myH = x.innerHeight; }\n'+
		'else if( d && d.clientWidth ) { myW = d.clientWidth; myH = d.clientHeight; }\n'+
		'else if( b && b.clientWidth ) { myW = b.clientWidth; myH = b.clientHeight; }\n'+
		'if( window.opera && !document.childNodes ) { myW += 16; }\n'+
		'x.resizeTo( oW = oW + ( ( oW + 100 ) - myW ), oH = oH + ( (oH + 100 ) - myH ) );\n'+
		'}\n'+
		'<\/script>'+
		'<\/head><body onload="resizeWinTo();"'+(AutoClose?' onblur="self.close();"':'')+'>'+
		(document.layers?('<layer left="0" top="0">'):('<div style="position:absolute;left:0px;top:0px;">'))+
		'<img src="'+imageURL+'" alt="Otevírám obrázek ..." title="kliknutím zavřete" onload="resizeWinTo();" onclick="window.close();">'+
		(document.layers?'<\/layer>':'<\/div>')+'<\/body><\/html>');
	imgWin.document.close();
	if( imgWin.focus ) { imgWin.focus(); }
	return false;
}





/* OKNO INFA */
function Okno()
{
okenko = window.open('','info','toolbar=no,width=290,height=500,directories=no,status=no,location=no,scrollbars=yes,resizable=no,menubar=no,left=0,top=0');	
okenko.document.write("<html><head><title>MOMENT</title></head>");
okenko.document.write("<body><h2 align=center>Moment načítám stránku ...</h2></body></html>");
okenko.focus();
}
