function getEl(sId) {
  return (document.all? document.all(sId): (document.getElementById? document.getElementById(sId): null));
};

function frameSet() {
  getEl('glavnaTablica').height  = document.body.clientHeight - 398;
}

	function svijetli(id) {
	
		tempPrvi = id;
		
		document.getElementById(tempPrvi).className=id + 'over';
	}
	
	function neSvijetli(id) {
		
		tempPrvi = id;
		
			document.getElementById(tempPrvi).className=id;
	}
	
	
function goPaging( nVar ) {
	document.searchResult.str.value = nVar;
	document.searchResult.submit();
}

function checkKvart() {
	if ( document.trazilica.regija.value != '1' ) {
		document.trazilica.kvart.disabled = true;
	}
	else {
		document.trazilica.kvart.disabled = false;
	}
}

function openPic( sVar )
{
  eval("var f=window.open('picture.asp?id=" + sVar + "','gallery','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=300 ,height=300');f.focus();");
}

function formCheck(){
	fali = "";
	
	if (document.obrazac.ime.value == "") fali = fali + "\n- Ime";
	if (document.obrazac.adresa.value == "") fali = fali + "\n- Adresu";
	if (document.obrazac.mjesto.value == "") fali = fali + "\n- Mjesto";
	if (document.obrazac.poruka.value == "") fali = fali + "\n- Poruku";
	if (fali != "")
	   alert("Niste upisali sve potrebne podatke!" + "\n\n" + "Molimo upišite:" + fali)
	else
	 document.obrazac.submit();
}

function karta(url,width,height)
{
 eval("window.open('slika.asp?s=" + url + "','_blank','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=" + width + ",height=" + height + "')");
}