//funkcje js
//(c) tomky at enedue.com

window.addEventListener = null;

//otwiera popup-a z obrazkiem
function show_pic(path, w, h, title) {
	l=(window.screen.width-w)/4;
	t=(window.screen.height-h)/4;
	winny=window.open('', 'pic', 'width='+w+', height='+h+', left='+l+', top='+t+', scrollbars=no');
	winny.document.write('<html><head><title>'+title+'</title></head><body style="background-color:white; margin:0px; overflow:hidden"><a href="javascript:window.close()"><img src="'+path+'" width="'+w+'" height="'+h+'" border="0"></a></body></html>');
	winny.focus();
}

//pop-up ze wskazana strona
function show_win(url, w, h, params) {
	if(window.winny) window.winny.close;
	if(params=='') params='resizable=no';
	l=(window.screen.width-w)/2;
	t=(window.screen.height-h)/3;
	winny=window.open(url, 'win', 'width='+w+', height='+h+', left='+l+', top='+t+', '+params);
	winny.focus();
}

//przy wysylaniu modyfikuje przycisk submit
function on_submit(butt_name) {
	//blokada przycisku wysylania submit
	document.getElementById(butt_name).disabled=true;
	document.getElementById(butt_name).value='czekaj...';
	document.getElementById(butt_name).style.cursor='wait';
}
