 var isIE=(window.ActiveXObject)?true:false;
 var isKHTML=(document.childNodes && !document.all && !navigator.taintEnabled)?true:false;
 var isGecko=(document.getBoxObjectFor != null)?true:false;
 var isOpera=(window.opera)?true:false;

  function getScrollHeight()
  {
    if (isIE) return Math.max(document.body.offsetHeight, document.body.scrollHeight);
    if (isKHTML) return Math.max(document.body.scrollHeight, document.body.clientHeight);
    return Math.max(document.documentElement.scrollHeight, document.body.clientHeight);;
  }

  function showcover(cnt)
  {
    var sctop=document.body.scrollTop;
    document.getElementById('cover').style.visibility='visible';
    document.getElementById('disp').style.visibility='visible';
    document.getElementById('disp').style.top=50+sctop;
    document.getElementById('disp').innerHTML=cnt;
    document.getElementById('cover').style.height=getScrollHeight();
    if (isIE) document.getElementById('cover').style.width=document.body.scrollWidth;
  }

  function hidecover()
  {
    document.getElementById('cover').style.visibility='hidden';
    document.getElementById('disp').style.visibility='hidden';
    document.getElementById('disp').innerHTML='';
  }

  function showcntgallery(gal, img, lng)
  {
    document.getElementById('loader').src='cntgallery.php?g='+gal+'&i='+img+'&l='+lng;
  }
  
  function showgallery(lng, gal, img)
  {
    document.getElementById('loader').src='gallery.php?g='+gal+'&i='+img+'&l='+lng;
  }
