
/* ---  u s t a w i e n i a --- */

_popup_druk_url = 'index_wydruk.php?';
_popup_druk_left = 20;
_popup_druk_top = 20;
_popup_druk_width = 560;
_popup_druk_height = 600;


_popup_polec_url = 'index_polec.php';
_popup_polec_left = 20;
_popup_polec_top = 20;
_popup_polec_width = 560;
_popup_polec_height = 350;



/* --- popup do operacji dodatkowych --- */
function popup(url, typ)
{
	switch (typ)
	{
		case 1: // drukowanie
				ourl = _popup_druk_url;
				ow = _popup_druk_width;
				oh = _popup_druk_height;
				ol = _popup_druk_left;
				ot = _popup_druk_top;
				break;
		case 3: // polec
				ourl = _popup_polec_url;
				ow = _popup_polec_width;
				oh = _popup_polec_height;
				ol = _popup_polec_left;
				ot = _popup_polec_top;
				break;
		default: break;
	}

	if (typ)
	{
		var wnd = window.open(ourl+url, 'popup_'+typ, "width="+ow+",height="+oh+",status=no,resizable=no,top="+ot+",left="+ol+",scrollbars=yes,dependent=yes,alwaysRaised=yes");
		wnd.focus();
	}
}



/* --- serwis, standard --- */
function str(obj,ov){
	if(ov==0){
		obj.className="str_aktywne";
	}
	if(ov==1){
		obj.className="str_nieaktywne";
	}
}

function showz(id, par, lng){
	szer = 50;
	wys = 50;
	var obj=window.open("zdjecie.php?idp="+id+"&par="+par+"&lng="+lng, "show","width="+szer+",height="+wys+",status=no,resizable=yes,top=20,left=20,scrollbars=no,dependent=yes,alwaysRaised=yes");
	obj.focus();
}

function ulubione(){
	window.external.addFavorite('http://www.zamek.otmuchow.pl','Zamek Otmuchów');
}

/* --- z edytora --- */
function zdjecie_e(zdj)
{
	var obj=window.open("e-cms/zdjecie_e.php?zdj="+zdj, 'zdjecie', "width=50,height=50,status=no,resizable=no,top=50,left=50,scrollbars=no,dependent=yes,alwaysRaised=yes");
	obj.focus();
}
