NewWindow = null;

function ShowItem(src, w, h){
if(NewWindow){NewWindow.close();}
if(NewWindow==null || NewWindow.closed){
 settings=
 "left=10,"
 +"top=20,"
 +"width=" + w + ","
 +"height=" + h + ","
 +"toolbar=no,"
 +"location=no,"
 +"directories=no,"
 +"status=no,"
 +"menubar=no,"
 +"scrollbars=no,"
 +"resizable=no"
 NewWindow = window.open("",'Klose',settings);
}
NewWindow.document.open();
NewWindow.document.clear();
NewWindow.document.write(
"<html><head><title>Fotogaléria</title></head>\n"
+"<body topmargin=0 leftmargin=0 onclick=window.close(); onblur=\"window.close();\""
+"onload=\"window.resizeTo(picture.width+10, picture.height+30);\" bgcolor=#FFFFFF>\n"
+"<img id=picture src=" + src + " style=\"cursor: hand\" title=\"zavrieť okno\" border=0>\n"
+"</body>\n"
+"</html>"
);
NewWindow.document.close();
NewWindow.focus();
}


// funkcia pre vymazanie formulára
function ClearForm(form){
form.vstup.value = "";
form.vypocitane.value = "";
}

// funkcia pre jednoduchú kontrolu vstupu
function checkform(form) {
 if (form.vstup.value==null||form.vstup.value.length==0){
      alert("\nZadajte vstupné dáta");
      return false;
 }
 return true;
}

// prepočet SKK-EUR
function skkeur(form) {
 if (checkform(form)) {             // kontrola vstupu
 skk=form.vstup.value;              // načítanie vstupu
 skk=skk.replace(',','.');          // ošetrenie vstupu
 eur=(skk/30.126);                  // prepočet mien
 eur=Math.round(eur*100)/100;       // zaokrúhlenie na 2 des. miesta
 form.vypocitane.value=eur+' €';    // výstup
 }
 return;
}

// prepočet EUR-SKK
function eurskk(form) {
 if (checkform(form)) {             // kontrola vstupu
 eur=form.vstup.value;              // načítanie vstupu
 eur=eur.replace(',','.');          // ošetrenie vstupu
 skk=(eur*30.126);                  // prepočet mien
 skk=Math.round(skk*100)/100;       // zaokrúhlenie na 2 des. miesta
 form.vypocitane.value=skk+' Sk';   // výstup
 }
 return;
}

<!--
   window.defaultStatus = 'Info_stránka obce DRUŽSTEVNÁ pri HORNÁDE';
//-->