<!--
<!--
// Global variables
var menuCur  = null;
var popupCur = null;
var uMargin  = 64;
var lMargin  = 160;
var pageCnt  = 0;
var menuType = null;

// zisti aky browser sa pouziva
isNS4 = (document.layers) ? 1 : 0;
isIE  = (document.all) ? 1 : 0;
isW3C = (document.getElementById && !document.all) ? 1 : 0;
isIE4Mac = ((navigator.appVersion.indexOf("Mac") != -1) && (document.all) && !(document.getElementById)) ? 1 : 0;

// blizsie overenie, toho, ci je naozaj IE
if (isIE)
{
  if (navigator.userAgent.indexOf("MSIE")==-1) isIE=0;
}

// mys nad polozkou menu
// implicitne sa popup menu neposuva 
function menuOver(popup)
{
  if (isIE) menuOverOff(popup, 0);
}
function menuOverOff(popup, offset)
{
  if (!isIE) return;
  var fel = event.fromElement;
  var tel = event.toElement;

  if (tel.tagName == 'TD') 
  { 
    menuCur = tel; menuType = tel.className; menuCur.className = 'menuHigh'; 
  }
  if (tel.tagName == 'A' && tel.parentElement.className == 'menuItem') 
  { 
    menuCur = tel.parentElement; menuCur.className = 'menuHigh';
    menuType = 'menuItem';
  }
  else if (tel.tagName == 'A' && tel.parentElement.className == 'menuSel') 
  { 
    menuCur = tel.parentElement; menuCur.className = 'menuHigh';
    menuType = 'menuSel';
  }

  
  // zobrazi popup menu
  if (menuCur != null)
  {
    // zlikviduj stare menu
    popupClear();

    if (popup != null)
    {
      var layer = document.all[popup];

      // treba pripocitat suradnice nadradenej tabulky
      layer.style.pixelLeft = lMargin + menuCur.offsetLeft - offset;
      layer.style.pixelTop = uMargin + menuCur.offsetTop + menuCur.offsetHeight;
      layer.style.display = "block";
      popupCur = popup;
    }
  }  
}

// mys opustila polozku menu
function menuOut()
{
  if (!isIE) return;
  var fel = event.fromElement;
  var tel = event.toElement;

  if (fel.tagName == 'TD')
  {
    fel.className = menuType; menuCur = null;
    popupOut();
  }
  else if (fel.tagName == 'A')
  {
    fel.parentElement.className = menuType; menuCur = null;
    popupOut();
  }
}

// cistenie stareho popup-menu
function popupClear()
{
  if (!isIE) return;
  if (popupCur != null)
  {
    var layer = document.all[popupCur];
    layer.style.display = "";
    popupCur = null;
  }
}

// mys opustila popu-menu
function popupOut()
{
  if (!isIE) return;
  var fel = event.fromElement;
  var tel = event.toElement;

  if (popupCur == null) return;

  // musi byt uplne mimo
  if (fel.className == 'popup') 
  {
    popupClear();
  }
  else
  {
    // hladaj nadriadenu triedu 'popup'
    while (tel != null)
    {
      if (tel.className == 'popup') break;
      tel = tel.parentElement;
    }
    if (tel == null)
    {
      popupClear();
    }
  }
}

function initArray() 
{
  this.length = initArray.arguments.length;
  for (var i = 0; i < this.length; i++)
    this[i+1] = initArray.arguments[i];
}

function showImg(imgname, x, y)
{
  if (isIE) {x+=20; y+=23};
  var name="../images/"+imgname+".jpg";
  ops = eval("'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=yes,width=" + x + ",height=" + y + "'");
  window.open(name, 'New1', ops);
  return;
}

function showAns(name)
{
  if (name==" ") return;
  name="ans/"+name+".htm";
  ops = eval("'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=yes,width=400,height=300,top=0,left=0'");
  window.open(name, "Ans", ops);
  return;
}

function show_faq(id)
{
  if (id==" ") return;
  name="faq1.php?id="+id;
  ops = eval("'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=yes,width=400,height=300,top=0,left=0'");
  window.open(name, "faq", ops);
  return;
}


function showPage(name)
{
  //if (!isIE) return;
  ops = eval("'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=yes'");
  window.open(name,pageCnt++,ops);
  return;  
}

function newSite(url)
{
  if (isIE) navigate(url);
  else window.location=url;
}
//-->
