﻿var vyber=0;
function highlight(x, w){
   if (x==vyber) return;
  

   stylLinky="linkaP";
   if (x==1) stylLinky="linkaLP";
   
   obj=document.getElementById("menu"+x);
    if (w==1) {
       obj.className=stylLinky + " najezd";
     } else
	 {
	   obj.className=stylLinky + " normal";
	 } 
}

function klik(x)
{
    switch (x) {
		case 1: self.location.href='default.aspx'; break;
		case 2: self.location.href='velek1.aspx'; break;
		case 3: self.location.href='velek2.aspx'; break;
		case 4: self.location.href='foto.aspx'; break;
	}
}

function zaklik(x)
{
   stylLinky="linkaP";
   if (x==1) stylLinky="linkaLP";
   obj=document.getElementById("menu"+x);
   obj.className=stylLinky + " najezd";
   vyber=x;		
}

//----------------------------------------------------------------

function fotoClose()
{
  if (window.foto != null) window.foto.close()
}

function fotoOpen(soubor, poloha)
{

     if (window.foto != null) window.foto.close()

     if (poloha == "h")
             {
                w=512
     		h=384   
             } else
             {
                w=384
     		h=512
             } 
  
     foto=window.open("","aa","width="+w+",height="+h+'"')
     
     foto.document.open()
     foto.document.writeln('<html>')
     foto.document.writeln('<head>')
     foto.document.writeln('<title>Foto ------------------------------</title>')
     foto.document.writeln('</head>')
     foto.document.writeln('<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">')
     foto.document.write('<img src="foto/'+soubor+'.jpg" width="'+w+'" height="'+h+'">')
     foto.document.writeln('</body>')
     foto.document.writeln('</html>')
     foto.document.close()
     window.foto.focus()
}
