<!--
// original code by Zdenek Mares
	WinLeftPreview = (screen.width)/2;
	WinTopPreview = (screen.height)/2 - 25;
	WinWidthPreview = 680;
	WinHeightPreview = 450;

	if (screen.height >= 580) {
		WinTopPreview = 0;
		WinHeightPreview = 450;
	};
	if (screen.height >= 750) {
		WinTopPreview = 0;
		WinHeightPreview = 550;
	};
	if (screen.height >= 850) {
		WinHeightPreview = 650;
	};
	if (screen.height >= 1000) {
		WinTopPreview = (screen.height)/2 - 25;
		WinHeightPreview = 650;
	};

function openWindow (Document,WindowName,Parameters) {
	window.open(Document,WindowName,Parameters);
}

function previewWindow (sParam) {
	nameWindow ('_default');
	openWindow('preview.asp?file=doc/' + sParam, 'Second', 'location=no,menubar=yes,toolbar=yes,scrollbars=yes,resizable=yes,width=' + WinWidthPreview + ', height=' + WinHeightPreview + ', left=' + (WinLeftPreview - (WinWidthPreview/2)) + ', top=' + (WinTopPreview - (WinHeightPreview/2)));
}

function nameWindow (WindowName) {
	window.name = WindowName;
	if (window.focus) {window.focus();}
}

function closeWindow () {
	window.close(this);
}

function obnovMenu (sParam) {
	parent._head.navigate('head.asp?menu=' + sParam);
}


//------------- reklama pop-up ------------------

	WinLeft = 100;
	WinTop = 100;
	WinWidth = 350;
	WinHeight = 280;

function OpenDocument (Document) {
	openWindow(Document, 'OpenDocument', 'location=no,menubar=no, toolbar=no, scrollbars=no, resizable=no, width=' + WinWidth + ',height=' + WinHeight + ',left=' + WinLeft + ',top=' + WinTop);
}

function reklama(Document) {
	var search = "reklama=otevr";
	var kolac = document.cookie.indexOf(search);
	//alert(kolac)
	if (kolac == -1) {
		openWindow(Document, 'reklama', 'location=no,menubar=no, toolbar=no, scrollbars=no, resizable=no, width=' + WinWidth + ',height=' + WinHeight + ',left=' + WinLeft + ',top=' + WinTop);
		document.cookie = "reklama=otevr";
	}
}	

//-->
