var DOKU_BASE   = '/vlhc/';var DOKU_TPL    = '/vlhc/lib/tpl/monobook/';var alertText   = 'Please enter the text you want to format.\nIt will be appended to the end of the document.';var notSavedYet = 'Unsaved changes will be lost.\nReally continue?';var reallyDel   = 'Really delete selected item(s)?';LANG = {"keepopen":"Keep window open on selection","hidedetails":"Hide Details","nosmblinks":"Linking to Windows shares only works in Microsoft Internet Explorer.\nYou still can copy and paste the link.","mu_btn":"Upload multiple files at once","plugins":[]};


/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/helpers.js XXXXXXXXXX */

/**
 * Differrent helper functions
 *
 * @author Ilya Lebedev <ilya@lebedev.net>
 * @license LGPL
 */
//-----------------------------------------------------------------------------
//  Variable/property checks
//-----------------------------------------------------------------------------
/**
 *  Checks if property is undefined
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isUndefined (prop /* :Object */) /* :Boolean */ {
  return (typeof prop == 'undefined');
}
/**
 *  Checks if property is function
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isFunction (prop /* :Object */) /* :Boolean */ {
  return (typeof prop == 'function');
}
/**
 *  Checks if property is string
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isString (prop /* :Object */) /* :Boolean */ {
  return (typeof prop == 'string');
}
/**
 *  Checks if property is number
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isNumber (prop /* :Object */) /* :Boolean */ {
  return (typeof prop == 'number');
}
/**
 *  Checks if property is the calculable number
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isNumeric (prop /* :Object */) /* :Boolean */ {
  return isNumber(prop)&&!isNaN(prop)&&isFinite(prop);
}
/**
 *  Checks if property is array
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isArray (prop /* :Object */) /* :Boolean */ {
  return (prop instanceof Array);
}
/**
 *  Checks if property is regexp
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isRegExp (prop /* :Object */) /* :Boolean */ {
  return (prop instanceof RegExp);
}
/**
 *  Checks if property is a boolean value
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isBoolean (prop /* :Object */) /* :Boolean */ {
  return ('boolean' == typeof prop);
}
/**
 *  Checks if property is a scalar value (value that could be used as the hash key)
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isScalar (prop /* :Object */) /* :Boolean */ {
  return isNumeric(prop)||isString(prop);
}
/**
 *  Checks if property is empty
 *
 *  @param {Object} prop value to check
 *  @return {Boolean} true if matched
 *  @scope public
 */
function isEmpty (prop /* :Object */) /* :Boolean */ {
  if (isBoolean(prop)) return false;
  if (isRegExp(prop) && new RegExp("").toString() == prop.toString()) return true;
  if (isString(prop) || isNumber(prop)) return !prop;
  if (Boolean(prop)&&false != prop) {
    for (var i in prop) if(prop.hasOwnProperty(i)) return false
  }
  return true;
}

/**
 *  Checks if property is derived from prototype, applies method if it is not exists
 *
 *  @param string property name
 *  @return bool true if prototyped
 *  @access public
 */
if ('undefined' == typeof Object.hasOwnProperty) {
  Object.prototype.hasOwnProperty = function (prop) {
    return !('undefined' == typeof this[prop] || this.constructor && this.constructor.prototype[prop] && this[prop] === this.constructor.prototype[prop]);
  }
}

/**
 * Very simplistic Flash plugin check, probably works for Flash 8 and higher only
 */
function hasFlash(version){
    var ver = 0;
    try{
        if(navigator.plugins != null && navigator.plugins.length > 0){
           ver = navigator.plugins["Shockwave Flash"].description.split(' ')[2].split('.')[0];
        }else{
           var axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
           ver = axo.GetVariable("$version").split(' ')[1].split(',')[0];
        }
    }catch(e){ }

    if(ver >= version) return true;
    return false;
}


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/helpers.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/events.js XXXXXXXXXX */

// written by Dean Edwards, 2005
// with input from Tino Zijdel

// http://dean.edwards.name/weblog/2005/10/add-event/

function addEvent(element, type, handler) {
    // assign each event handler a unique ID
    if (!handler.$$guid) handler.$$guid = addEvent.guid++;
    // create a hash table of event types for the element
    if (!element.events) element.events = {};
    // create a hash table of event handlers for each element/event pair
    var handlers = element.events[type];
    if (!handlers) {
        handlers = element.events[type] = {};
        // store the existing event handler (if there is one)
        if (element["on" + type]) {
            handlers[0] = element["on" + type];
        }
    }
    // store the event handler in the hash table
    handlers[handler.$$guid] = handler;
    // assign a global event handler to do all the work
    element["on" + type] = handleEvent;
};
// a counter used to create unique IDs
addEvent.guid = 1;

function removeEvent(element, type, handler) {
    // delete the event handler from the hash table
    if (element.events && element.events[type]) {
        delete element.events[type][handler.$$guid];
    }
};

function handleEvent(event) {
    var returnValue = true;
    // grab the event object (IE uses a global event object)
    event = event || fixEvent(window.event);
    // get a reference to the hash table of event handlers
    var handlers = this.events[event.type];
    // execute each event handler
    for (var i in handlers) {
        if (!handlers.hasOwnProperty(i)) continue;
        this.$$handleEvent = handlers[i];
        if (this.$$handleEvent(event) === false) {
            returnValue = false;
        }
    }
    return returnValue;
};

function fixEvent(event) {
    // add W3C standard event methods
    event.preventDefault = fixEvent.preventDefault;
    event.stopPropagation = fixEvent.stopPropagation;
    // fix target
    event.target = event.srcElement;
    return event;
};
fixEvent.preventDefault = function() {
    this.returnValue = false;
};
fixEvent.stopPropagation = function() {
    this.cancelBubble = true;
};


/**
 * Pseudo event handler to be fired after the DOM was parsed or
 * on window load at last.
 *
 * @author based upon some code by Dean Edwards
 * @author Dean Edwards
 * @link   http://dean.edwards.name/weblog/2006/06/again/
 */
window.fireoninit = function() {
  // quit if this function has already been called
  if (arguments.callee.done) return;
  // flag this function so we don't do the same thing twice
  arguments.callee.done = true;
  // kill the timer
  if (_timer) {
     clearInterval(_timer);
     _timer = null;
  }

  if (typeof window.oninit == 'function') {
        window.oninit();
  }
};

/**
 * Run the fireoninit function as soon as possible after
 * the DOM was loaded, using different methods for different
 * Browsers
 *
 * @author Dean Edwards
 * @link   http://dean.edwards.name/weblog/2006/06/again/
 */
  // for Mozilla
  if (document.addEventListener) {
    document.addEventListener("DOMContentLoaded", window.fireoninit, null);
  }

  // for Internet Explorer (using conditional comments)
  /*@cc_on @*/
  /*@if (@_win32)
    document.write("<scr" + "ipt id=\"__ie_init\" defer=\"true\" src=\"//:\"><\/script>");
    var script = document.getElementById("__ie_init");
    script.onreadystatechange = function() {
        if (this.readyState == "complete") {
            window.fireoninit(); // call the onload handler
        }
    };
  /*@end @*/

  // for Safari
  if (/WebKit/i.test(navigator.userAgent)) { // sniff
    var _timer = setInterval(function() {
        if (/loaded|complete/.test(document.readyState)) {
            window.fireoninit(); // call the onload handler
        }
    }, 10);
  }

  // for other browsers
  window.onload = window.fireoninit;


/**
 * This is a pseudo Event that will be fired by the fireoninit
 * function above.
 *
 * Use addInitEvent to bind to this event!
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 * @see fireoninit()
 */
window.oninit = function(){};

/**
 * Bind a function to the window.init pseudo event
 *
 * @author Simon Willison
 * @see http://simon.incutio.com/archive/2004/05/26/addLoadEvent
 */
function addInitEvent(func) {
  var oldoninit = window.oninit;
  if (typeof window.oninit != 'function') {
    window.oninit = func;
  } else {
    window.oninit = function() {
      oldoninit();
      func();
    };
  }
}




/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/events.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/cookie.js XXXXXXXXXX */

/**
 * Handles the cookie used by several JavaScript functions
 *
 * Only a single cookie is written and read. You may only save
 * sime name-value pairs - no complex types!
 *
 * You should only use the getValue and setValue methods
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */
DokuCookie = {
    data: Array(),
    name: 'DOKU_PREFS',

    /**
     * Save a value to the cookie
     *
     * @author Andreas Gohr <andi@splitbrain.org>
     */
    setValue: function(key,val){
        DokuCookie.init();
        DokuCookie.data[key] = val;

        // prepare expire date
        var now = new Date();
        DokuCookie.fixDate(now);
        now.setTime(now.getTime() + 365 * 24 * 60 * 60 * 1000); //expire in a year

        //save the whole data array
        var text = '';
        for(var key in DokuCookie.data){
            if (!DokuCookie.data.hasOwnProperty(key)) continue;
            text += '#'+escape(key)+'#'+DokuCookie.data[key];
        }
        DokuCookie.setCookie(DokuCookie.name,text.substr(1),now,DOKU_BASE);
    },

    /**
     * Get a Value from the Cookie
     *
     * @author Andreas Gohr <andi@splitbrain.org>
     */
    getValue: function(key){
        DokuCookie.init();
        return DokuCookie.data[key];
    },

    /**
     * Loads the current set cookie
     *
     * @author Andreas Gohr <andi@splitbrain.org>
     */
    init: function(){
        if(DokuCookie.data.length) return;
        var text  = DokuCookie.getCookie(DokuCookie.name);
        if(text){
            var parts = text.split('#');
            for(var i=0; i<parts.length; i+=2){
                DokuCookie.data[unescape(parts[i])] = unescape(parts[i+1]);
            }
        }
    },

    /**
     * This sets a cookie by JavaScript
     *
     * @link http://www.webreference.com/js/column8/functions.html
     */
    setCookie: function(name, value, expires, path, domain, secure) {
        var curCookie = name + "=" + escape(value) +
            ((expires) ? "; expires=" + expires.toGMTString() : "") +
            ((path) ? "; path=" + path : "") +
            ((domain) ? "; domain=" + domain : "") +
            ((secure) ? "; secure" : "");
        document.cookie = curCookie;
    },

    /**
     * This reads a cookie by JavaScript
     *
     * @link http://www.webreference.com/js/column8/functions.html
     */
    getCookie: function(name) {
        var dc = document.cookie;
        var prefix = name + "=";
        var begin = dc.indexOf("; " + prefix);
        if (begin == -1) {
            begin = dc.indexOf(prefix);
            if (begin !== 0){ return null; }
        } else {
            begin += 2;
        }
        var end = document.cookie.indexOf(";", begin);
        if (end == -1){
            end = dc.length;
        }
        return unescape(dc.substring(begin + prefix.length, end));
    },

    /**
     * This is needed for the cookie functions
     *
     * @link http://www.webreference.com/js/column8/functions.html
     */
    fixDate: function(date) {
        var base = new Date(0);
        var skew = base.getTime();
        if (skew > 0){
            date.setTime(date.getTime() - skew);
        }
    }
};


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/cookie.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/script.js XXXXXXXXXX */

/**
 * Some of these scripts were taken from wikipedia.org and were modified for DokuWiki
 */

/**
 * Some browser detection
 */
var clientPC  = navigator.userAgent.toLowerCase(); // Get client info
var is_macos  = navigator.appVersion.indexOf('Mac') != -1;
var is_gecko  = ((clientPC.indexOf('gecko')!=-1) && (clientPC.indexOf('spoofer')==-1) &&
                (clientPC.indexOf('khtml') == -1) && (clientPC.indexOf('netscape/7.0')==-1));
var is_safari = ((clientPC.indexOf('AppleWebKit')!=-1) && (clientPC.indexOf('spoofer')==-1));
var is_khtml  = (navigator.vendor == 'KDE' || ( document.childNodes && !document.all && !navigator.taintEnabled ));
if (clientPC.indexOf('opera')!=-1) {
    var is_opera = true;
    var is_opera_preseven = (window.opera && !document.childNodes);
    var is_opera_seven = (window.opera && document.childNodes);
}

// prepare empty toolbar for checks by lazy plugins
var toolbar = '';

/**
 * Handy shortcut to document.getElementById
 *
 * This function was taken from the prototype library
 *
 * @link http://prototype.conio.net/
 */
function $() {
  var elements = new Array();

  for (var i = 0; i < arguments.length; i++) {
    var element = arguments[i];
    if (typeof element == 'string')
      element = document.getElementById(element);

    if (arguments.length == 1)
      return element;

    elements.push(element);
  }

  return elements;
}

/**
 * Simple function to check if a global var is defined
 *
 * @author Kae Verens
 * @link http://verens.com/archives/2005/07/25/isset-for-javascript/#comment-2835
 */
function isset(varname){
  return(typeof(window[varname])!='undefined');
}

/**
 * Select elements by their class name
 *
 * @author Dustin Diaz <dustin [at] dustindiaz [dot] com>
 * @link   http://www.dustindiaz.com/getelementsbyclass/
 */
function getElementsByClass(searchClass,node,tag) {
    var classElements = new Array();
    if ( node == null )
        node = document;
    if ( tag == null )
        tag = '*';
    var els = node.getElementsByTagName(tag);
    var elsLen = els.length;
    var pattern = new RegExp("(^|\\s)"+searchClass+"(\\s|$)");
    for (i = 0, j = 0; i < elsLen; i++) {
        if ( pattern.test(els[i].className) ) {
            classElements[j] = els[i];
            j++;
        }
    }
    return classElements;
}

/**
 * Get the X offset of the top left corner of the given object
 *
 * @link http://www.quirksmode.org/index.html?/js/findpos.html
 */
function findPosX(object){
  var curleft = 0;
  var obj = $(object);
  if (obj.offsetParent){
    while (obj.offsetParent){
      curleft += obj.offsetLeft;
      obj = obj.offsetParent;
    }
  }
  else if (obj.x){
    curleft += obj.x;
  }
  return curleft;
} //end findPosX function

/**
 * Get the Y offset of the top left corner of the given object
 *
 * @link http://www.quirksmode.org/index.html?/js/findpos.html
 */
function findPosY(object){
  var curtop = 0;
  var obj = $(object);
  if (obj.offsetParent){
    while (obj.offsetParent){
      curtop += obj.offsetTop;
      obj = obj.offsetParent;
    }
  }
  else if (obj.y){
    curtop += obj.y;
  }
  return curtop;
} //end findPosY function

/**
 * Escape special chars in JavaScript
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */
function jsEscape(text){
    var re=new RegExp("\\\\","g");
    text=text.replace(re,"\\\\");
    re=new RegExp("'","g");
    text=text.replace(re,"\\'");
    re=new RegExp('"',"g");
    text=text.replace(re,'&quot;');
    re=new RegExp("\\\\\\\\n","g");
    text=text.replace(re,"\\n");
    return text;
}

/**
 * This function escapes some special chars
 * @deprecated by above function
 */
function escapeQuotes(text) {
  var re=new RegExp("'","g");
  text=text.replace(re,"\\'");
  re=new RegExp('"',"g");
  text=text.replace(re,'&quot;');
  re=new RegExp("\\n","g");
  text=text.replace(re,"\\n");
  return text;
}

/**
 * Adds a node as the first childenode to the given parent
 *
 * @see appendChild()
 */
function prependChild(parent,element) {
    if(!parent.firstChild){
        parent.appendChild(element);
    }else{
        parent.insertBefore(element,parent.firstChild);
    }
}

/**
 * Prints a animated gif to show the search is performed
 *
 * Because we need to modify the DOM here before the document is loaded
 * and parsed completely we have to rely on document.write()
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */
function showLoadBar(){

  document.write('<img src="'+DOKU_BASE+'lib/images/loading.gif" '+
                 'width="150" height="12" alt="..." />');

  /* this does not work reliable in IE
  obj = $(id);

  if(obj){
    obj.innerHTML = '<img src="'+DOKU_BASE+'lib/images/loading.gif" '+
                    'width="150" height="12" alt="..." />';
    obj.style.display="block";
  }
  */
}

/**
 * Disables the animated gif to show the search is done
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */
function hideLoadBar(id){
  obj = $(id);
  if(obj) obj.style.display="none";
}

/**
 * Adds the toggle switch to the TOC
 */
function addTocToggle() {
    if(!document.getElementById) return;
    var header = $('toc__header');
    if(!header) return;

    var obj          = document.createElement('span');
    obj.id           = 'toc__toggle';
    obj.innerHTML    = '<span>&minus;</span>';
    obj.className    = 'toc_close';
    obj.style.cursor = 'pointer';

    prependChild(header,obj);
    obj.parentNode.onclick = toggleToc;
    try {
       obj.parentNode.style.cursor = 'pointer';
       obj.parentNode.style.cursor = 'hand';
    }catch(e){}
}

/**
 * This toggles the visibility of the Table of Contents
 */
function toggleToc() {
  var toc = $('toc__inside');
  var obj = $('toc__toggle');
  if(toc.style.display == 'none') {
    toc.style.display   = '';
    obj.innerHTML       = '<span>&minus;</span>';
    obj.className       = 'toc_close';
  } else {
    toc.style.display   = 'none';
    obj.innerHTML       = '<span>+</span>';
    obj.className       = 'toc_open';
  }
}

/**
 * This enables/disables checkboxes for acl-administration
 *
 * @author Frank Schubert <frank@schokilade.de>
 */
function checkAclLevel(){
  if(document.getElementById) {
    var scope = $('acl_scope').value;

    //check for namespace
    if( (scope.indexOf(":*") > 0) || (scope == "*") ){
      document.getElementsByName('acl_checkbox[4]')[0].disabled=false;
      document.getElementsByName('acl_checkbox[8]')[0].disabled=false;
    }else{
      document.getElementsByName('acl_checkbox[4]')[0].checked=false;
      document.getElementsByName('acl_checkbox[8]')[0].checked=false;

      document.getElementsByName('acl_checkbox[4]')[0].disabled=true;
      document.getElementsByName('acl_checkbox[8]')[0].disabled=true;
    }
  }
}

/**
 * Display an insitu footnote popup
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 * @author Chris Smith <chris@jalakai.co.uk>
 */
function footnote(e){
    var obj = e.target;
    var id = obj.id.substr(5);

    // get or create the footnote popup div
    var fndiv = $('insitu__fn');
    if(!fndiv){
        fndiv = document.createElement('div');
        fndiv.id        = 'insitu__fn';
        fndiv.className = 'insitu-footnote JSpopup dokuwiki';

        // autoclose on mouseout - ignoring bubbled up events
        addEvent(fndiv,'mouseout',function(e){
            if(e.target != fndiv){
                e.stopPropagation();
                return;
            }
            // check if the element was really left
            if(e.pageX){        // Mozilla
                var bx1 = findPosX(fndiv);
                var bx2 = bx1 + fndiv.offsetWidth;
                var by1 = findPosY(fndiv);
                var by2 = by1 + fndiv.offsetHeight;
                var x = e.pageX;
                var y = e.pageY;
                if(x > bx1 && x < bx2 && y > by1 && y < by2){
                    // we're still inside boundaries
                    e.stopPropagation();
                    return;
                }
            }else{              // IE
                if(e.offsetX > 0 && e.offsetX < fndiv.offsetWidth-1 &&
                   e.offsetY > 0 && e.offsetY < fndiv.offsetHeight-1){
                    // we're still inside boundaries
                    e.stopPropagation();
                    return;
                }
            }
            // okay, hide it
            fndiv.style.display='none';
        });
        document.body.appendChild(fndiv);
    }

    // locate the footnote anchor element
    var a = $( "fn__"+id );
    if (!a){ return; }

    // anchor parent is the footnote container, get its innerHTML
    var content = new String (a.parentNode.parentNode.innerHTML);

    // strip the leading content anchors and their comma separators
    content = content.replace(/<sup>.*<\/sup>/gi, '');
    content = content.replace(/^\s+(,\s+)+/,'');

    // prefix ids on any elements with "insitu__" to ensure they remain unique
    content = content.replace(/\bid=\"(.*?)\"/gi,'id="insitu__$1');

    // now put the content into the wrapper
    fndiv.innerHTML = content;

    // position the div and make it visible
    var x; var y;
    if(e.pageX){        // Mozilla
        x = e.pageX;
        y = e.pageY;
    }else{              // IE
        x = e.offsetX;
        y = e.offsetY;
    }
    fndiv.style.position = 'absolute';
    fndiv.style.left = (x+2)+'px';
    fndiv.style.top  = (y+2)+'px';
    fndiv.style.display = '';
}

/**
 * Add the event handlers to footnotes
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */
addInitEvent(function(){
    var elems = getElementsByClass('fn_top',null,'a');
    for(var i=0; i<elems.length; i++){
        addEvent(elems[i],'mouseover',function(e){footnote(e);});
    }
});

/**
 * Add the edit window size controls
 */
function initSizeCtl(ctlid,edid){
    if(!document.getElementById){ return; }

    var ctl      = $(ctlid);
    var textarea = $(edid);
    if(!ctl || !textarea) return;

    var hgt = DokuCookie.getValue('sizeCtl');
    if(hgt){
      textarea.style.height = hgt;
    }else{
      textarea.style.height = '300px';
    }

    var wrp = DokuCookie.getValue('wrapCtl');
    if(wrp){
      setWrap(textarea, wrp);
    } // else use default value

    var l = document.createElement('img');
    var s = document.createElement('img');
    var w = document.createElement('img');
    l.src = DOKU_BASE+'lib/images/larger.gif';
    s.src = DOKU_BASE+'lib/images/smaller.gif';
    w.src = DOKU_BASE+'lib/images/wrap.gif';
    addEvent(l,'click',function(){sizeCtl(edid,100);});
    addEvent(s,'click',function(){sizeCtl(edid,-100);});
    addEvent(w,'click',function(){toggleWrap(edid);});
    ctl.appendChild(l);
    ctl.appendChild(s);
    ctl.appendChild(w);
}

/**
 * This sets the vertical size of the editbox
 */
function sizeCtl(edid,val){
  var textarea = $(edid);
  var height = parseInt(textarea.style.height.substr(0,textarea.style.height.length-2));
  height += val;
  textarea.style.height = height+'px';

  DokuCookie.setValue('sizeCtl',textarea.style.height);
}

/**
 * Toggle the wrapping mode of a textarea
 */
function toggleWrap(edid){
    var textarea = $(edid);
    var wrap = textarea.getAttribute('wrap');
    if(wrap && wrap.toLowerCase() == 'off'){
        setWrap(textarea, 'soft');
    }else{
        setWrap(textarea, 'off');
    }

    DokuCookie.setValue('wrapCtl',textarea.getAttribute('wrap'));
}

/**
 * Set the wrapping mode of a textarea
 *
 * @author Fluffy Convict <fluffyconvict@hotmail.com>
 * @author <shutdown@flashmail.com>
 * @link   http://news.hping.org/comp.lang.javascript.archive/12265.html
 * @link   https://bugzilla.mozilla.org/show_bug.cgi?id=41464
 */
function setWrap(textarea, wrapAttrValue){
    textarea.setAttribute('wrap', wrapAttrValue);

    // Fix display for mozilla
    var parNod = textarea.parentNode;
    var nxtSib = textarea.nextSibling;
    parNod.removeChild(textarea);
    parNod.insertBefore(textarea, nxtSib);
}

/**
 * Handler to close all open Popups
 */
function closePopups(){
  if(!document.getElementById){ return; }

  var divs = document.getElementsByTagName('div');
  for(var i=0; i < divs.length; i++){
    if(divs[i].className.indexOf('JSpopup') != -1){
            divs[i].style.display = 'none';
    }
  }
}

/**
 * Looks for an element with the ID scroll__here at scrolls to it
 */
function scrollToMarker(){
    var obj = $('scroll__here');
    if(obj) obj.scrollIntoView();
}

/**
 * Looks for an element with the ID focus__this at sets focus to it
 */
function focusMarker(){
    var obj = $('focus__this');
    if(obj) obj.focus();
}

/**
 * Remove messages
 */
function cleanMsgArea(){
    var elems = getElementsByClass('(success|info|error)',document,'div');
    if(elems){
        for(var i=0; i<elems.length; i++){
            elems[i].style.display = 'none';
        }
    }
}

/**
 * disable multiple revisions checkboxes if two are checked
 *
 * @author Anika Henke <anika@selfthinker.org>
 */
addInitEvent(function(){
    var revForm = $('page__revisions');
    if (!revForm) return;
    var elems = revForm.elements;
    var countTicks = 0;
    for (var i=0; i<elems.length; i++) {
        var input1 = elems[i];
        if (input1.type=='checkbox') {
            addEvent(input1,'click',function(e){
                if (this.checked) countTicks++;
                else countTicks--;
                for (var j=0; j<elems.length; j++) {
                    var input2 = elems[j];
                    if (countTicks >= 2) input2.disabled = (input2.type=='checkbox' && !input2.checked);
                    else input2.disabled = (input2.type!='checkbox');
                }
            });
        }
    }
});

/**
 * Add the event handler to the actiondropdown
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */
addInitEvent(function(){
    var selector = $('action__selector');
    if(!selector) return;

    addEvent(selector,'change',function(e){
        this.form.submit();
    });

    $('action__selectorbtn').style.display = 'none';
});

/**
 * Display error for Windows Shares on browsers other than IE
 *
 * Michael Klier <chi@chimeric.de>
 */
function checkWindowsShares() {
    var elems = getElementsByClass('windows',document,'a');
    if(elems){
        for(var i=0; i<elems.length; i++){
            var share = elems[i];
            addEvent(share,'click',function(){
                if(document.all == null) {
                    alert(LANG['nosmblinks']);
                }
            });
        }
    }
}

/**
 * Add the event handler for the Windows Shares check
 *
 * Michael Klier <chi@chimeric.de>
 */
addInitEvent(function(){
    checkWindowsShares();
});


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/tw-sack.js XXXXXXXXXX */

/* Simple AJAX Code-Kit (SACK) */
/* Â©2005 Gregory Wild-Smith */
/* www.twilightuniverse.com */
/* Software licenced under a modified X11 licence, see documentation or authors website for more details */

function sack(file){
  this.AjaxFailedAlert = "Your browser does not support the enhanced functionality of this website, and therefore you will have an experience that differs from the intended one.\n";
  this.requestFile = file;
  this.method = "POST";
  this.URLString = "";
  this.encodeURIString = true;
  this.execute = false;

  this.onLoading = function() { };
  this.onLoaded = function() { };
  this.onInteractive = function() { };
  this.onCompletion = function() { };
  this.afterCompletion = function() { };

  this.createAJAX = function() {
    try {
      this.xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
    } catch (e) {
      try {
        this.xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
      } catch (err) {
        this.xmlhttp = null;
      }
    }
    if(!this.xmlhttp && typeof XMLHttpRequest != "undefined"){
      this.xmlhttp = new XMLHttpRequest();
    }
    if (!this.xmlhttp){
      this.failed = true;
    }
  };

  this.setVar = function(name, value){
    if (this.URLString.length < 3){
      this.URLString = name + "=" + value;
    } else {
      this.URLString += "&" + name + "=" + value;
    }
  };

  this.encVar = function(name, value){
    var varString = encodeURIComponent(name) + "=" + encodeURIComponent(value);
  return varString;
  };

  this.encodeURLString = function(string){
    varArray = string.split('&');
    for (i = 0; i < varArray.length; i++){
      urlVars = varArray[i].split('=');
      if (urlVars[0].indexOf('amp;') != -1){
        urlVars[0] = urlVars[0].substring(4);
      }
      varArray[i] = this.encVar(urlVars[0],urlVars[1]);
    }
  return varArray.join('&');
  };

  this.runResponse = function(){
    eval(this.response);
  };

  this.runAJAX = function(urlstring){
    this.responseStatus = new Array(2);
    if(this.failed && this.AjaxFailedAlert){
      alert(this.AjaxFailedAlert);
    } else {
      if (urlstring){
        if (this.URLString.length){
          this.URLString = this.URLString + "&" + urlstring;
        } else {
          this.URLString = urlstring;
        }
      }
      if (this.encodeURIString){
        var timeval = new Date().getTime();
        this.URLString = this.encodeURLString(this.URLString);
        this.setVar("rndval", timeval);
      }
      if (this.element) { this.elementObj = document.getElementById(this.element); }
      if (this.xmlhttp) {
        var self = this;
        if (this.method == "GET") {
          var totalurlstring = this.requestFile + "?" + this.URLString;
          this.xmlhttp.open(this.method, totalurlstring, true);
        } else {
          this.xmlhttp.open(this.method, this.requestFile, true);
        }
        if (this.method == "POST"){
          try {
             this.xmlhttp.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=UTF-8');
          } catch (e) {}
        }

        this.xmlhttp.onreadystatechange = function() {
          switch (self.xmlhttp.readyState){
            case 1:
              self.onLoading();
            break;
            case 2:
              self.onLoaded();
            break;
            case 3:
              self.onInteractive();
            break;
            case 4:
              self.response = self.xmlhttp.responseText;
              self.responseXML = self.xmlhttp.responseXML;
              self.responseStatus[0] = self.xmlhttp.status;
              self.responseStatus[1] = self.xmlhttp.statusText;
              self.onCompletion();
              if(self.execute){ self.runResponse(); }
              if (self.elementObj) {
                var elemNodeName = self.elementObj.nodeName;
                elemNodeName.toLowerCase();
                if (elemNodeName == "input" || elemNodeName == "select" || elemNodeName == "option" || elemNodeName == "textarea"){
                  self.elementObj.value = self.response;
                } else {
                  self.elementObj.innerHTML = self.response;
                }
              }
              self.afterCompletion();
              self.URLString = "";
            break;
          }
        };
        this.xmlhttp.send(this.URLString);
      }
    }
  };
this.createAJAX();
}


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/tw-sack.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/ajax.js XXXXXXXXXX */

/**
 * AJAX functions for the pagename quicksearch
 *
 * We're using a global object with self referencing methods
 * here to make callbacks work
 *
 * @license  GPL2 (http://www.gnu.org/licenses/gpl.html)
 * @author   Andreas Gohr <andi@splitbrain.org>
 */

//prepare class
function ajax_qsearch_class(){
  this.sack = null;
  this.inObj = null;
  this.outObj = null;
  this.timer = null;
}

//create global object and add functions
var ajax_qsearch = new ajax_qsearch_class();
ajax_qsearch.sack = new sack(DOKU_BASE + 'lib/exe/ajax.php');
ajax_qsearch.sack.AjaxFailedAlert = '';
ajax_qsearch.sack.encodeURIString = false;

ajax_qsearch.init = function(inID,outID){
  ajax_qsearch.inObj  = document.getElementById(inID);
  ajax_qsearch.outObj = document.getElementById(outID);

  // objects found?
  if(ajax_qsearch.inObj === null){ return; }
  if(ajax_qsearch.outObj === null){ return; }

  // attach eventhandler to search field
  addEvent(ajax_qsearch.inObj,'keyup',ajax_qsearch.call);

  // attach eventhandler to output field
  addEvent(ajax_qsearch.outObj,'click',function(){ ajax_qsearch.outObj.style.display='none'; });
};

ajax_qsearch.clear = function(){
  ajax_qsearch.outObj.style.display = 'none';
  ajax_qsearch.outObj.innerHTML = '';
  if(ajax_qsearch.timer !== null){
    window.clearTimeout(ajax_qsearch.timer);
    ajax_qsearch.timer = null;
  }
};

ajax_qsearch.exec = function(){
  ajax_qsearch.clear();
  var value = ajax_qsearch.inObj.value;
  if(value === ''){ return; }
  ajax_qsearch.sack.runAJAX('call=qsearch&q='+encodeURI(value));
};

ajax_qsearch.sack.onCompletion = function(){
  var data = ajax_qsearch.sack.response;
  if(data === ''){ return; }

  ajax_qsearch.outObj.innerHTML = data;
  ajax_qsearch.outObj.style.display = 'block';
};

ajax_qsearch.call = function(){
  ajax_qsearch.clear();
  ajax_qsearch.timer = window.setTimeout("ajax_qsearch.exec()",500);
};



/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/ajax.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/index.js XXXXXXXXXX */

/**
 * Javascript for index view
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */

index = {

     /**
     * Delay in ms before showing the throbber.
     * Used to skip the throbber for fast AJAX calls.
     */
    throbber_delay: 500,

    /**
     * Attach event handlers to all "folders" below the given element
     *
     * @author Andreas Gohr <andi@splitbrain.org>
     */
    treeattach: function(obj){
        if(!obj) return;

        var items = getElementsByClass('idx_dir',obj,'a');
        for(var i=0; i<items.length; i++){
            var elem = items[i];

            // attach action to make the link clickable by AJAX
            addEvent(elem,'click',function(e){ return index.toggle(e,this); });

            // get the listitem the elem belongs to
            var listitem = elem.parentNode;
            while (listitem.tagName != 'LI') {
              listitem = listitem.parentNode;
            }
            //when there are uls under this listitem mark this listitem as opened
            if (listitem.getElementsByTagName('ul').length) {
              listitem.open = true;
            }
        }
    },

    /**
     * Open or close a subtree using AJAX
     * The contents of subtrees are "cached" untill the page is reloaded.
     * A "loading" indicator is shown only when the AJAX call is slow.
     *
     * @author Andreas Gohr <andi@splitbrain.org>
     * @author Ben Coburn <btcoburn@silicodon.net>
     */
    toggle: function(e,clicky){
        var listitem = clicky.parentNode.parentNode;

        listitem.open = !listitem.open;
        // listitem.open represents now the action to be done

        // if already open, close by removing the sublist
        var sublists = listitem.getElementsByTagName('ul');
        if(!listitem.open){
            if (sublists.length) {
              sublists[0].style.display='none';
            }
            listitem.className='closed';
            e.preventDefault();
            return false;
        }

        // just show if already loaded
        if(sublists.length && listitem.open){
            sublists[0].style.display='';
            listitem.className='open';
            e.preventDefault();
            return false;
        }

        // prepare an AJAX call to fetch the subtree
        var ajax = new sack(DOKU_BASE + 'lib/exe/ajax.php');
        ajax.AjaxFailedAlert = '';
        ajax.encodeURIString = false;
        if(ajax.failed) return true;

        //prepare the new ul
        var ul = document.createElement('ul');
        ul.className = 'idx';
        timeout = window.setTimeout(function(){
            // show the throbber as needed
            if (listitem.open) {
              ul.innerHTML = '<li><img src="'+DOKU_BASE+'lib/images/throbber.gif" alt="loading..." title="loading..." /></li>';
              listitem.appendChild(ul);
              listitem.className='open';
            }
        }, this.throbber_delay);
        ajax.elementObj = ul;
        ajax.afterCompletion = function(){
            window.clearTimeout(timeout);
            index.treeattach(ul);
            if (listitem.className!='open') {
              if (!listitem.open) {
                ul.style.display='none';
              }
              listitem.appendChild(ul);
              if (listitem.open) {
                listitem.className='open';
              }
            }
        };
        ajax.runAJAX(clicky.search.substr(1)+'&call=index');
        e.preventDefault();
        return false;
    }
};


addInitEvent(function(){
    index.treeattach($('index__tree'));
});


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/scripts/index.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/tpl/monobook/script.js XXXXXXXXXX */



/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/tpl/monobook/script.js XXXXXXXXXX */

addInitEvent(function(){ ajax_qsearch.init('qsearch__in','qsearch__out'); });
addInitEvent(function(){ addEvent(document,'click',closePopups); });
addInitEvent(function(){ addTocToggle(); });


/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/fontcolor/script.js XXXXXXXXXX */

/* javascript function to create fontcolor toolbar in dokuwiki */
/* see http://www.dokuwiki.org/plugin:fontcolor for more info */
 
var plugin_fontcolor_colors = {
 
  "Yellow":      "#ffff00",
  "Red":         "#ff0000",
  "Orange":      "#ffa500",
  "Salmon":      "#fa8072",
  "Pink":        "#ffc0cb",
  "Plum":        "#dda0dd",
  "Purple":      "#800080",
  "Fuchsia":     "#ff00ff",
  "Silver":      "#c0c0c0",
  "Aqua":        "#00ffff",
  "Teal":        "#008080",
  "Cornflower":  "#6495ed",
  "Sky Blue":    "#87ceeb",
  "Aquamarine":  "#7fffd4",
  "Pale Green":  "#98fb98",
  "Lime":        "#00ff00",
  "Green":       "#008000",
  "Olive":       "#808000",
  "Indian Red":  "#cd5c5c",
  "Khaki":       "#f0e68c",
  "Powder Blue": "#b0e0e6",
  "Sandy Brown": "#f4a460",
  "Steel Blue":  "#4682b4",
  "Thistle":     "#d8bfd8",
  "Yellow Green":"#9acd32",
  "Dark Violet": "#9400d3",
  "Maroon":      "#800000"
 
};
 
function plugin_fontcolor_make_color_button(name, value) {
 
  var btn = document.createElement('button');
 
  btn.className = 'pickerbutton';
  btn.value = ' ';
  btn.title = name;
  btn.style.height = '2em';
  btn.style.padding = '1em';
  btn.style.backgroundColor = value;
 
  var open = "<fc " + value + ">";
  var close ="<\/fc>";
  var sample = name + " fontcolor";
  eval("btn.onclick = function(){ insertTags( '"
    + jsEscape('wiki__text') + "','"
    + jsEscape(open) + "','"
    + jsEscape(close)+"','"
    + jsEscape(sample) + "'); return false; } "
  );
 
  return(btn);
 
}
 
function plugin_fontcolor_toolbar_picker() {
 
  var toolbar = document.getElementById('tool__bar');
  if (!toolbar) return;
 
  // Create the picker button
  var p_id = 'picker_plugin_fontcolor'; // picker id that we're creating
  var p_ico = document.createElement('img');
  p_ico.src = DOKU_BASE + 'lib/plugins/fontcolor/images/toolbar_icon.png';
  var p_btn = document.createElement('button');
  p_btn.className = 'toolbutton';
  p_btn.title = 'fontcolor';
  p_btn.appendChild(p_ico);
  eval("p_btn.onclick = function() { showPicker('"
    + p_id + "',this); return false; }");
 
  // Create the picker <div>
  var picker = document.createElement('div');
  picker.className = 'picker';
  picker.id = p_id;
  picker.style.position = 'absolute';
  picker.style.display = 'none';
 
  // Add a button to the picker <div> for each of the colors
  for( var color in plugin_fontcolor_colors ) {
    var btn = plugin_fontcolor_make_color_button(color,
        plugin_fontcolor_colors[color]);
    picker.appendChild(btn);
  }
  if (typeof user_fontcolor_colors != 'undefined') {
    for( var color in user_fontcolor_colors ) {
      var btn = plugin_fontcolor_make_color_button(color,
          user_fontcolor_colors[color]);
      picker.appendChild(btn);
    }
  }
 
  var body = document.getElementsByTagName('body')[0];
  body.appendChild(picker);     // attach the picker <div> to the page body
  toolbar.appendChild(p_btn);   // attach the picker button to the toolbar
}
addInitEvent(plugin_fontcolor_toolbar_picker);
 
//Setup VIM: ex: et ts=2 sw=2 enc=utf-8 :

/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/fontcolor/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/frootysearch/script.js XXXXXXXXXX */

/**
 * frootySearch changes your standard Search input field into somewhat elegant looking
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author     i-net software <tools@inetsoftware.de>
 * @author     Gerry Weißbach <gweissbach@inetsoftware.de>
 */
var frootySearch__searchDecorator = function() {

									var searchField = $('qsearch__in');
									if ( !searchField ) { return; }
									var searchButton = searchField.nextSibling;
									if ( typeof(searchField) == 'undefined' || searchField === null ) {return;}
									if (	searchButton && searchButton.nodeName == 'input' &&
											searchButton.className == 'button' ) {
											searchButton.style.display = 'none';
									}

									searchField.setAttribute('autocomplete', 'off');

									// Get the Submitbutton
									var button = null;
									var tmp = searchField.parentNode.firstChild;
									while( tmp && !button ) {
										if ( frootySearch__hasClassName(tmp, 'button') ) {
											button = tmp;
											continue;
										}

										tmp = tmp.nextSibling;
									}
									
									if ( !button ) { return; }

									var label = document.createElement('label');
									label.setAttribute('for', searchField.id);
									searchField.parentNode.insertBefore(label, searchField);
									label.appendChild(searchField);

									var placeholder = button.value.split('\n')[0];
									button.parentNode.removeChild(button);
									button = null;

									var standIn = null;

									if(is_safari) {

										searchField.setAttribute('type', 'search');

										searchField.setAttribute('autosave', 'off');
										searchField.setAttribute('placeholder', placeholder);
										searchField.setAttribute('results', 0);
									} else {
										standIn = document.createElement("input");
										var left = document.createElement("div");
										frootySearch__addClassName(left, "left");
										var right = document.createElement("div");
										frootySearch__addClassName(right, "right");
										var reset = document.createElement("div");
										frootySearch__addClassName(reset, "reset");
										var wrapper = document.createElement("div");
										frootySearch__addClassName(wrapper, "frootySearch");
										var alreadyHasplaceholder = searchField.value == placeholder;
										var isEmpty = searchField.value.length == 0;
										if (alreadyHasplaceholder || isEmpty) {
											searchField.value = placeholder;
											frootySearch__addClassName(wrapper, "blurred");
											frootySearch__addClassName(wrapper, "empty");
										}
										
										searchField.parentNode.replaceChild(standIn, searchField);
										wrapper.appendChild(left);
										left.appendChild(searchField);
										left.appendChild(right);
										left.appendChild(reset);
										
										var focus = function () {var blurred = frootySearch__hasClassName(wrapper, "blurred");if (searchField.value == placeholder && blurred) {searchField.value = "";}frootySearch__removeClassName(wrapper, "blurred");};
										addEvent(searchField, "focus", focus);
										var blur = function () {if (searchField.value == "") {frootySearch__addClassName(wrapper, "empty");searchField.value = placeholder;}frootySearch__addClassName(wrapper, "blurred");};
										addEvent(searchField, "blur", blur);
										var toggleReset = function () {if (searchField.value.length >= 0) {frootySearch__removeClassName(wrapper, "empty");}};
										addEvent(searchField, "keydown", toggleReset);
										var resetField = function () {return function (evt) {var escaped = false;if (evt.type == "keydown") {if (evt.keyCode != 27) {return;} else {escaped = true;}}searchField.blur();searchField.value = "";frootySearch__addClassName(wrapper, "empty");document.getElementById('qsearch__out').style.display='none';searchField.focus();};};
										addEvent(reset, "mousedown", resetField());
										addEvent(searchField, "keydown", resetField());
										if (standIn) {
											standIn.parentNode.replaceChild(wrapper, standIn);
										}
									}
};

/* Function taken from prototype library */
var frootySearch__addClassName = function(element, className) {
	if (!(element = $(element))) return;
	if (!frootySearch__hasClassName(element, className))
		element.className += (element.className ? ' ' : '') + className;
	return element;
};

/* Function taken from prototype library */
var frootySearch__hasClassName = function(element, className) {
	if (!(element = $(element))) return;
	var elementClassName = element.className;
	return (elementClassName.length > 0 && (elementClassName == className ||
		new RegExp("(^|\\s)" + className + "(\\s|$)").test(elementClassName)));
};

/* Function taken from prototype library */
var frootySearch__removeClassName = function(element, className) {
	if (!(element = $(element))) return;
	/* reimplementation of replace ... */
	element.className = String(element.className).replace(new RegExp("(^|\\s+)" + className + "(\\s+|$)"), ' ').replace(/^\s+/, '').replace(/\s+$/, '');
	return element;
};

addInitEvent(frootySearch__searchDecorator);


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/frootysearch/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/fullindex/script.js XXXXXXXXXX */

/*
Based on Stuart Langridge's aqtree3clickable.js (http://www.kryogenix.org/code/browser/aqlists/)
*/


function makeTreesC() {
    // We don't actually need createElement, but we do
    // need good DOM support, so this is a good check.
    if (!document.createElement) return;
    
    uls = document.getElementsByTagName("ul");
    for (uli=0;uli<uls.length;uli++) {
        ul = uls[uli];
        if (ul.nodeName == "UL" && ul.className == "aqtree3clickable") {
            processULELC(ul);
        }
    }
}

function processULELC(ul) {
    if (!ul.childNodes || ul.childNodes.length == 0) return;
    // Iterate LIs
    for (var itemi=0;itemi<ul.childNodes.length;itemi++) {
        var item = ul.childNodes[itemi];
        if (item.nodeName == "LI") {
            // Iterate things in this LI
            var a;
            var subul;
	    	subul = "";
            for (var sitemi=0;sitemi<item.childNodes.length;sitemi++) {
                var sitem = item.childNodes[sitemi];
                switch (sitem.nodeName) {
                    case "A": a = sitem; break;
                    case "SPAN": a = sitem; break;
                    case "UL": subul = sitem; 
                               processULELC(subul);
                               break;
                }
            }
            if (subul) {
                associateELC(a,subul);
            } else {
                a.parentNode.className = "bullet";
            }
        }
    }
}

function associateELC(a,ul) {
	var el = document.createElement("a");
	var img = document.createElement("img");
	img.src="lib/plugins/fullindex/images/open.gif";
	el.appendChild(img);
	el.className = "cat";
	a.parentNode.insertBefore(el, a.parentNode.firstChild);
    if (a.parentNode.className.indexOf('open') == -1)
		a.parentNode.className = 'closed';
	el.onclick = function () {
        if (this.parentNode.className=='open') {
        	this.parentNode.className = "closed";
			this.firstChild.src="lib/plugins/fullindex/images/closed.gif";
        } else {
        	this.parentNode.className = "open";
			this.firstChild.src="lib/plugins/fullindex/images/open.gif";
        }
        return false;
    }
}

function aq_collapseAll() {
	//walk through entire tree and change "open" to "closed" class
    uls = document.getElementsByTagName("ul");
    for (uli=0;uli<uls.length;uli++) {
        ul = uls[uli];
        if (ul.nodeName == "UL" && ul.className == "aqtree3clickable") {
			if (!ul.childNodes || ul.childNodes.length == 0) return;
			for (var itemi=0;itemi<ul.childNodes.length;itemi++) {
				var item = ul.childNodes[itemi];
				item.className = 'closed';
			}
        }
    }
}

function aq_showLevel(ul, level, currLevel) {
	currLevel = currLevel + 1;
    if (!ul.childNodes || ul.childNodes.length == 0) return;
    // Iterate LIs
    for (var itemi=0;itemi<ul.childNodes.length;itemi++) {
        var item = ul.childNodes[itemi];
        if (item.nodeName == "LI") {
            // Iterate things in this LI
            var subul;
	    	subul = "";
	    	var hasChild;
	    	//if not reached level look for ul and process recursively
	    	if (currLevel < level){
				for (var sitemi=0;sitemi<item.childNodes.length;sitemi++) {
					var sitem = item.childNodes[sitemi];
					switch (sitem.nodeName) {
					  case "UL": subul = sitem; 
					    aq_showLevel(subul, level, currLevel);
					    hasChild = true;
						break;
					}
				}
				if (hasChild) {
					item.className = 'open';
					hasChild = false;
				} else {
					item.className = 'bullet';
				}
			} else {
				//check to see if there's a end node
				for (var sitemi=0;sitemi<item.childNodes.length;sitemi++) {
					var sitem = item.childNodes[sitemi];
					switch (sitem.nodeName) {
					  case "UL": subul = sitem; 
					    hasChild = true;
						break;
					}
				}
				if (hasChild) {
					item.className = 'closed';
					item.firstChild.firstChild.src="lib/plugins/fullindex/images/closed.gif";
					hasChild = false;
				} else {
					item.className = 'bullet';
				}
            }
        }
    }
}


function aq_show(level, obj) {
	//walk through entire tree and change "open" to "closed" class based on the level passed
    uls = document.getElementsByTagName("ul");
    for (uli=0;uli<uls.length;uli++) {
        ul = uls[uli];
        if (ul.nodeName == "UL" && ul.className == "aqtree3clickable") {
        	if(level > 0) {
        		aq_set(obj);
            	aq_showLevel(ul, level, 0);
            }
        }
    }
}

//find the clicked item and set classes accordingly
function aq_set(obj) {
    var ul = document.getElementById("aqNav");
    for (i=0;i<ul.childNodes.length;i++) {
    	var li = ul.childNodes[i];
    	//find clicked item
    	if(li.id == obj.parentNode.id) {
    		li.className = "on";
    	} else {
    		li.className = "";
    	}
    }
}

//initialize
addInitEvent(makeTreesC);


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/fullindex/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/folded/script.js XXXXXXXXXX */

/*
 * For Folded Text Plugin
 *
 * @author Fabian van-de-l_Isle <webmaster [at] lajzar [dot] co [dot] uk>
 * @author Christopher Smith <chris [at] jalakai [dot] co [dot] uk>
 */

// containers for localised reveal/hide strings, 
// populated from html comments in hidden elements on the page
var folded_reveal = 'reveal';
var folded_hide = 'hide';

/*
 * toggle the folded element via className change
 * also adjust the classname and title tooltip on the folding link
 */
function folded_toggle(evt) {
  id = this.href.match(/#(.*)$/)[1];
  e = $(id);
  if (!e) return;

  if (e.className.match(/\bhidden\b/)) {
    e.className = e.className.replace(/\bhidden\b/g,'');
    e.className = e.className.replace(/  /g,' ');

    this.title = folded_hide;

    this.className += ' open';
  } else {
    e.className += ' hidden';

    this.title = folded_reveal;

    this.className = this.className.replace(/\bopen\b/g,'');
    this.className = this.className.replace(/  /g,' ');
  }

  evt.preventDefault();
  return false;
}

/*
 * run on document load, setup everything we need
 */
function folded_setup() {
  
  // extract and save localised title tooltip strings
  var eStrings = $('folded_reveal','folded_hide');
  if (!eStrings[0]) return;

  folded_reveal = eStrings[0].innerHTML.match(/^<!-- (.*) -->$/)[1];
  folded_hide = eStrings[1].innerHTML.match(/^<!-- (.*) -->$/)[1];

  // find all folder links, assign onclick handler and title tooltip for initial state
  var folds = getElementsByClass('folder');
  for (var i=0; i<folds.length; i++) {    
    addEvent(folds[i], 'click', folded_toggle);
    folds[i].title = folded_reveal;
  }
}

addInitEvent(folded_setup);

// support graceful js degradation, this hides the folded blocks from view before they are shown, 
// whilst still allowing non-js user to see any folded content.
document.write('<style type="text/css" media="screen"><!--/*--><![CDATA[/*><!--*/ .folded.hidden { display: none; } .folder .indicator { visibility: visible; } /*]]>*/--></style>');


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/folded/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/permissioninfo/script.js XXXXXXXXXX */

function piToggleView(viewtype, groupname)
{
	var e = document.getElementById('pi'+viewtype+groupname);
	// Action to display
	var action = ""; 
	if(!e)
	{
		return;
	}
	
	// Toggle visibility of view
	if(e.style.display == "block" || e.style.display == "")
	{
		e.style.display = "none";
		action = 'show';
	}
	else
	{
		e.style.display = "block";
		action = 'hide';
	}
	
	// Change link Text
	var idx = action+"_"+viewtype.toLowerCase();
	var text = piLang[idx];

	var e = document.getElementById('piViewToggler'+viewtype+groupname).innerHTML=text;
	
}


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/permissioninfo/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/usermanager/script.js XXXXXXXXXX */

/**
 * Add JavaScript confirmation to the User Delete button
 */
function usrmgr_delconfirm(){
    if($('usrmgr__del')){
        addEvent( $('usrmgr__del'),'click',function(){ return confirm(reallyDel); } );
    }
};
addInitEvent(usrmgr_delconfirm);


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/usermanager/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/searchindex/script.js XXXXXXXXXX */

/**
 * Javascript for searchindex manager plugin
 *
 * @author Andreas Gohr <andi@splitbrain.org>
 */

/**
 * Class to hold some values
 */
function plugin_searchindex_class(){
    this.pages = null;
    this.page = null;
    this.sack = null;
    this.done = 1;
    this.count = 0;
}
var pl_si = new plugin_searchindex_class();
pl_si.sack = new sack(DOKU_BASE + 'lib/plugins/searchindex/ajax.php');
pl_si.sack.AjaxFailedAlert = '';
pl_si.sack.encodeURIString = false;

/**
 * Display the loading gif
 */
function plugin_searchindex_throbber(on){
    obj = document.getElementById('pl_si_throbber');
    if(on){
        obj.style.visibility='visible';
    }else{
        obj.style.visibility='hidden';
    }
}

/**
 * Gives textual feedback
 */
function plugin_searchindex_status(text){
    obj = document.getElementById('pl_si_out');
    obj.innerHTML = text;
}

/**
 * Callback. Gets the list of all pages
 */
function plugin_searchindex_cb_clear(){
    ok = this.response;
    if(ok == 1){
        // start indexing
        window.setTimeout("plugin_searchindex_index()",1000);
    }else{
        plugin_searchindex_status(ok);
        // retry
        window.setTimeout("plugin_searchindex_clear()",5000);
    }
}

/**
 * Callback. Gets the list of all pages
 */
function plugin_searchindex_cb_pages(){
    data = this.response;
    pl_si.pages = data.split("\n");
    pl_si.count = pl_si.pages.length;
    plugin_searchindex_status(pl_si.pages.length+" pages found");

    pl_si.page = pl_si.pages.shift();
    window.setTimeout("plugin_searchindex_clear()",1000);
}

/**
 * Callback. Gets the info if indexing of a page was successful
 *
 * Calls the next index run.
 */
function plugin_searchindex_cb_index(){
    ok = this.response;
    if(ok == 1){
        pl_si.page = pl_si.pages.shift();
        pl_si.done++;
        // get next one
        window.setTimeout("plugin_searchindex_index()",1000);
    }else{
        plugin_searchindex_status(ok);
        // get next one
        window.setTimeout("plugin_searchindex_index()",5000);
    }
}

/**
 * Starts the indexing of a page.
 */
function plugin_searchindex_index(){
    if(pl_si.page){
        plugin_searchindex_status('indexing '+pl_si.page+' ('+pl_si.done+'/'+pl_si.count+')');
        pl_si.sack.onCompletion = plugin_searchindex_cb_index;
        pl_si.sack.URLString = '';
        pl_si.sack.runAJAX('call=indexpage&page='+encodeURI(pl_si.page));
    }else{
        plugin_searchindex_status('finished');
        plugin_searchindex_throbber(false);
    }
}

/**
 * Cleans the index
 */
function plugin_searchindex_clear(){
    plugin_searchindex_status('clearing index...');
    pl_si.sack.onCompletion = plugin_searchindex_cb_clear;
    pl_si.sack.URLString = '';
    pl_si.sack.runAJAX('call=clearindex');
}

/**
 * Starts the whole index rebuild process
 */
function plugin_searchindex_go(){
    document.getElementById('pl_si_gobtn').style.display = 'none';
    plugin_searchindex_throbber(true);

    plugin_searchindex_status('Finding all pages');
    pl_si.sack.onCompletion = plugin_searchindex_cb_pages;
    pl_si.sack.URLString = '';
    pl_si.sack.runAJAX('call=pagelist');
}

//Setup VIM: ex: et ts=4 enc=utf-8 :


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/searchindex/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/fontsize2/script.js XXXXXXXXXX */

/* javascript function to create fontsize2 toolbar in dokuwiki */
/* see http://wiki.splitbrain.org/plugin:fontsize2 for more info */

var plugin_fontsize2 = {

  "0_5":      "0.5em",
  "0_6":         "0.6em",
  "0_7":      "0.7em",
  "0_8":      "0.8em",
  "0_9":      "0.9em", 
  "1":        "1em",
  "1_1":        "1.1em",
  "1_2":        "1.2em",
  "1_4":        "1.4em",
  "1_6":        "1.6em",
  "1_8":        "1.8em",
  "2":        "2em",
  "2_2":        "2.2em",
  "2_4":        "2.4em",
  "2_6":        "2.6em",
  "2_8":        "2.8em",
  "3":        "3em",
  "3_5":        "3.5em",
  "4":        "4em",
  "4_5":        "4.5em",
  "5":        "5em",
  "5_5":        "5.5em",
  "6":        "6em",
  "6_5":        "6.5em",
  "7":        "7em",
  "8":        "8em",
  "9":        "9em",
  "10":        "10em" 
};

if (isUndefined(user_fontsize2)) {
  var user_fontsize2 = { };
}

function plugin_fontsize2_make_fontsize2_button(name, value) {

  var b_id = name;	// picker id that we're creating
  var b_ico = document.createElement('img');
  b_ico.src = DOKU_BASE + 'lib/plugins/fontsize2/images/'+name+'.png';
  var btn = document.createElement('button');

  btn.className = 'pickerbutton';
  btn.value = value;
  btn.title = name;
  btn.style.height = '10em';
  btn.style.padding = '0em';
  btn.name = value;
  btn.appendChild(b_ico);
  
  var open = "<fs " + value + ">";
  var close ="<\/fs>";
  var sample = name + " 100%";

  eval("btn.onclick = function(){ insertTags( '"
    + jsEscape('wiki__text') + "','"
    + jsEscape(open) + "','"
    + jsEscape(close) + "','"
    + jsEscape(sample) + "'); return false; } "
  );

  return(btn);

}

function plugin_fontsize2_toolbar_picker() {

                  // Check that we are editing the page - is there a better way to do this?
                  var edbtn = document.getElementById('edbtn__save');
                  if (!edbtn) return;
                  
                  var toolbar = document.getElementById('tool__bar');
                  if (!toolbar) return;

  // Create the picker button
  var p_id = 'picker_plugin_fontsize2';	// picker id that we're creating
  var p_ico = document.createElement('img');
  p_ico.src = DOKU_BASE + 'lib/plugins/fontsize2/images/toolbar_icon.png';
  var p_btn = document.createElement('button');
  p_btn.className = 'toolbutton';
  p_btn.title = 'Fontsize';
  p_btn.appendChild(p_ico);
  eval("p_btn.onclick = function() { showPicker('" 
    + p_id + "',this); return false; }");

  // Create the picker <div>
  var picker = document.createElement('div');
  picker.className = 'picker';
  picker.id = p_id;
  picker.style.position = 'absolute';
  picker.style.display = 'none';

  /// Add a button to the picker <div> for each of the colors
  for( var fs in plugin_fontsize2 ) {
    if (!isFunction(plugin_fontsize2[fs])) {
      var btn = plugin_fontsize2_make_fontsize2_button(fs,
          plugin_fontsize2[fs]);
      picker.appendChild(btn);
    }
  }
  


  var body = document.getElementsByTagName('body')[0];
  body.appendChild(picker);	// attach the picker <div> to the page body
  toolbar.appendChild(p_btn);	// attach the picker button to the toolbar
}

addInitEvent(plugin_fontsize2_toolbar_picker);

//Setup VIM: ex: et ts=2 sw=2 enc=utf-8 :


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/fontsize2/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/code/script.js XXXXXXXXXX */

// JavaScript behaviour for 'code' syntax plugin  -  2008-07-22
// Copyright (C) 2005, 2008  M.Watermann, D-10247 Berlin, FRG  -  <support@mwat.de>

var syntax_plugin_code=function(){var _cH=' codeHidden',_cS=' codeShown',_reH=/\s*\bcodeHidden\b/gi,_reS=/\s*\bcodeShown\b/gi,_ini='syntax_plugin_code.js()',_Divs=function(){var d,l,r=[];try{if((d=window.document.getElementsByTagName('div'))&&(l=d.length)){var e,re=/\bcode\b/i;do{if((e=d[--l])&&(e.className)&&re.test(e.className)){r[r.length]=e;}}while(0<l);}}catch(X){X=0;}return r;},_Ps=function(){var d=_Divs(),l,r=[];_Divs=0;if((l=d.length)){var e,fc,fcn,lc,lcn,p='p',pf='pre';try{do{if((e=d[--l])&&(fc=e.firstChild)&&(fcn=fc.tagName.toLowerCase())&&(lc=e.lastChild)&&(lcn=lc.tagName.toLowerCase())){if((pf==fcn)&&(p==lcn)){lc._PRE=fc;r[r.length]=lc;}else if((pf==lcn)&&(p==fcn)){fc._PRE=lc;r[r.length]=fc;}}d.length=l;}while(0<l);}catch(X){X=0;}}return r;};function _sw(anObj,aRE2Del,aCss2Add){aRE2Del.lastIndex=0;if(aRE2Del.test(anObj.className)){aRE2Del.lastIndex=0;anObj.className=(aCss2Add)?anObj.className.replace(aRE2Del,aCss2Add):anObj.className.replace(aRE2Del,'');}else if(aCss2Add){anObj.className+=aCss2Add;}aRE2Del.lastIndex=0;}function _toggle(anEvent){if((anEvent=anEvent||window.event)){anEvent.cancelBubble=true;anEvent.returnValue=false;}if(this.className){if(_reH.test(this.className)){_sw(this._PRE,_reH,_cS);_sw(this,_reH,_cS);}else{_sw(this,_reS,_cH);_sw(this._PRE,_reS,_cH);}}else{this.className=this._PRE.className=_cH;}return false;}function ini(){if(_Ps){_ini=0;}else{return;}var d=_Ps(),l;_Ps=0;if((l=d.length)){var p,re=/\s*\bHideOnInit\b/ig;do{if((p=d[--l])&&(p._PRE)){if(re.test(p.className)){re.lastIndex=0;p._PRE.className+=_cH;p.className=p.className.replace(re,_cH);}else{p._PRE.className+=_cS;p.className+=_cS;}p.onclick=_toggle;re.lastIndex=0;}}while(0<l);}}if('undefined'!=typeof(window.addEvent)){try{window.addEvent(window,'load',ini);}catch(X){X=0;window.setTimeout(_ini,512);}}else{window.setTimeout(_ini,512);}return{js:ini};}();


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/code/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/highlight/script.js XXXXXXXXXX */

/* javascript function to create highlight toolbar in dokuwiki */
/* see http://wiki.splitbrain.org/plugin:highlight for more info */

var plugin_highlight_colors = {

  "Yellow":      "#ffff00",
  "Red":         "#ff0000",
  "Orange":      "#ffa500",
  "Salmon":      "#fa8072",
  "Pink":        "#ffc0cb",
  "Plum":        "#dda0dd",
  "Purple":      "#800080",
  "Fuchsia":     "#ff00ff",
  "Silver":      "#c0c0c0",
  "Aqua":        "#00ffff",
  "Teal":        "#008080",
  "Cornflower":  "#6495ed",
  "Sky Blue":    "#87ceeb",
  "Aquamarine":  "#7fffd4",
  "Pale Green":  "#98fb98",
  "Lime":        "#00ff00",
  "Green":       "#008000",
  "Olive":       "#808000"

};

function plugin_highlight_make_color_button(name, value) {

  var btn = document.createElement('button');

  btn.className = 'pickerbutton';
  btn.value = ' ';
  btn.title = name;
  btn.style.height = '2em';
  btn.style.padding = '1em';
  btn.style.backgroundColor = value;

  var open = "<hi " + value + ">";
  var close ="<\/hi>";
  var sample = name + " Highlighted Text";
  eval("btn.onclick = function(){ insertTags( '"
    + jsEscape('wiki__text') + "','"
    + jsEscape(open) + "','"
    + jsEscape(close)+"','"
    + jsEscape(sample) + "'); return false; } "
  );

  return(btn);

}

function plugin_highlight_toolbar_picker() {

  // Check that we are editing the page - is there a better way to do this?
  var edbtn = document.getElementById('edbtn__save');
  if (!edbtn) return;
  
  var toolbar = document.getElementById('tool__bar');
  if (!toolbar) return;

  // Create the picker button
  var p_id = 'picker_plugin_highlight';	// picker id that we're creating
  var p_ico = document.createElement('img');
  p_ico.src = DOKU_BASE + 'lib/plugins/highlight/toolbar_icon.png';
  var p_btn = document.createElement('button');
  p_btn.className = 'toolbutton';
  p_btn.title = 'Highlight Text';
  p_btn.appendChild(p_ico);
  eval("p_btn.onclick = function() { showPicker('" 
    + p_id + "',this); return false; }");

  // Create the picker <div>
  var picker = document.createElement('div');
  picker.className = 'picker';
  picker.id = p_id;
  picker.style.position = 'absolute';
  picker.style.display = 'none';

  // Add a button to the picker <div> for each of the colors
  for( var color in plugin_highlight_colors ) {
    var btn = plugin_highlight_make_color_button(color,
        plugin_highlight_colors[color]);
    picker.appendChild(btn);
  }
  if (typeof user_highlight_colors != 'undefined') {
    for( var color in user_highlight_colors ) {
      var btn = plugin_highlight_make_color_button(color,
          user_highlight_colors[color]);
      picker.appendChild(btn);
    }
  }

  var body = document.getElementsByTagName('body')[0];
  body.appendChild(picker);	// attach the picker <div> to the page body
  toolbar.appendChild(p_btn);	// attach the picker button to the toolbar
}
addInitEvent(plugin_highlight_toolbar_picker);

//Setup VIM: ex: et ts=2 sw=2 enc=utf-8 :


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/highlight/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/googlemaps/script.js XXXXXXXXXX */


/*
 *  Javascript associated with googlemaps plugin
 */


function in_array(needle, haystack) {
  for (var i=0; i<haystack.length; i++)
    if (haystack[i] == needle) return true;

  return false;
}

// Creates a marker at the given point with the given number label
// from http://www.google.com/apis/maps/documentation/#Display_Info_Windows_Above_Markers
// with minor modifications
function create_marker(point, text) {
  var marker = new GMarker(point);
  GEvent.addListener(marker, "click", function() {
    marker.openInfoWindowHtml(text);
  });
  return marker;
}

function init_googlemaps() {

  // nothing to do?
  if (googlemap.length == 0) return;

  var maptypes = { map : G_NORMAL_MAP,
                   normal : G_NORMAL_MAP,
                   hybrid : G_HYBRID_MAP,
                   satellite : G_SATELLITE_MAP
                 };

  // retrieve all google map containers
  var nodes = document.body.getElementsByTagName('div');

  var i=0;
  for (var j=0; j<nodes.length; j++) {
    if (nodes[j].className.match(/\bgooglemap\b/)) {
      googlemap[i++].node = nodes[j];
    }
  }

  // iterate through all the map containers and set up each map
  for (i=0; i<googlemap.length; i++) {
    googlemap[i].map = new GMap2(googlemap[i].node);

    with (googlemap[i]) {
      if (controls == 'on') {
        map.addControl(new GSmallMapControl());
        map.addControl(new GMapTypeControl());
      }
      map.setCenter(new GLatLng(lat, lon), zoom);  

      var supported = map.getMapTypes();
      var requested = maptypes[type];

      map.setMapType(in_array(requested,supported) ? requested : supported[0]);

      if (googlemap[i].overlay && overlay.length > 0) {
        for (j=0; j<overlay.length; j++) {
          map.addOverlay(create_marker(new GLatLng(overlay[j].lat,overlay[j].lon),overlay[j].txt));
        }
      }
    }
  }


  addEvent(document.body, 'unload', GUnload);
}


var googlemap = new Array();
addInitEvent(init_googlemaps);


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/googlemaps/script.js XXXXXXXXXX */



/* XXXXXXXXXX begin of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/acl/script.js XXXXXXXXXX */

acl = {
    init: function(){
        this.ctl = $('acl_manager');
        if(!this.ctl) return;

        var sel = $('acl__user').getElementsByTagName('select')[0];

        addEvent(sel,'change',acl.userselhandler);
        addEvent($('acl__tree'),'click',acl.treehandler);
        addEvent($('acl__user').getElementsByTagName('input')[1],'click',acl.loadinfo);
    },


    /**
     * Handle user dropdown
     */
    userselhandler: function(e){
        // make entry field visible/invisible
        if(this.value == '__g__' || this.value == '__u__'){
            $('acl__user').getElementsByTagName('input')[0].style.display = ''; //acl_w
            $('acl__user').getElementsByTagName('input')[1].style.display = ''; //submit
        }else{
            $('acl__user').getElementsByTagName('input')[0].style.display = 'none';
            $('acl__user').getElementsByTagName('input')[1].style.display = 'none';
        }

        acl.loadinfo();
    },

    /**
     * Load the current permission info and edit form
     *
     * @param frm - Form element with needed data
     */
    loadinfo: function(){
        // get form
        var frm = $('acl__detail').getElementsByTagName('form')[0];

        // prepare an AJAX call
        var ajax = new sack(DOKU_BASE + 'lib/plugins/acl/ajax.php');
        ajax.AjaxFailedAlert = '';
        ajax.encodeURIString = false;
        if(ajax.failed) return true;

        // prepare data
        var data = Array();
        data[0] = ajax.encVar('ns',frm.elements['ns'].value);
        data[1] = ajax.encVar('id',frm.elements['id'].value);
        data[2] = ajax.encVar('acl_t',frm.elements['acl_t'].value);
        data[3] = ajax.encVar('acl_w',frm.elements['acl_w'].value);
        data[4] = ajax.encVar('ajax','info');

        ajax.elementObj = $('acl__info');

        ajax.runAJAX(data.join('&'));
        return false;
    },

    /**
     * parse URL attributes into a associative array
     *
     * @todo put into global script lib?
     */
    parseatt: function(str){
        if(str[0] == '?') str = str.substr(1);
        var attributes = {};
        var all = str.split('&');
        for(var i=0; i<all.length; i++){
            var att = all[i].split('=');
            attributes[att[0]] = decodeURIComponent(att[1]);
        }
        return attributes;
    },

    /**
     * htmlspecialchars equivalent
     *
     * @todo put in gloabl scripts lib?
     */
    hsc: function(str) {
        str = str.replace(/&/g,"&amp;");
        str = str.replace(/\"/g,"&quot;");
        str = str.replace(/\'/g,"&#039;");
        str = str.replace(/</g,"&lt;");
        str = str.replace(/>/g,"&gt;");
        return str;
    },


    /**
     * Open or close a subtree using AJAX
     *
     * @author Andreas Gohr <andi@splitbrain.org>
     */
    treetoggle: function(clicky){
        var listitem = clicky.parentNode.parentNode;

        // if already open, close by removing the sublist
        var sublists = listitem.getElementsByTagName('ul');
        if(sublists.length){
            listitem.removeChild(sublists[0]);
            clicky.src = DOKU_BASE+'lib/images/plus.gif';
            clicky.alt = '+';
            return false;
        }

        // get the enclosed link (is always the first one)
        var link = listitem.getElementsByTagName('a')[0];

        // prepare an AJAX call to fetch the subtree
        var ajax = new sack(DOKU_BASE + 'lib/plugins/acl/ajax.php');
        ajax.AjaxFailedAlert = '';
        ajax.encodeURIString = false;
        if(ajax.failed) return true;

        //prepare the new ul
        var ul = document.createElement('ul');
        listitem.appendChild(ul);
        ajax.elementObj = ul;
        ajax.runAJAX(link.search.substr(1)+'&ajax=tree');
        clicky.src = DOKU_BASE+'lib/images/minus.gif';
        return false;
    },

    /**
     * Handles all clicks in the tree, dispatching the right action based on the
     * clicked element
     */
    treehandler: function(e){
        if(e.target.src){ // is it an image?
            acl.treetoggle(e.target);
        } else if(e.target.href){ // is it a link?
            // remove highlighting
            var obj = getElementsByClass('cur',$('acl__tree'),'a');
            for(var i=0; i<obj.length; i++){
                obj[i].className = obj[i].className.replace(/ cur/,'');
            }

            // add new highlighting
            e.target.className += ' cur';

            // set new page to detail form
            var frm = $('acl__detail').getElementsByTagName('form')[0];
            if(e.target.className.search(/wikilink1/) > -1){
                frm.elements['ns'].value = '';
                frm.elements['id'].value = acl.hsc(acl.parseatt(e.target.search)['id']);
            }else if(e.target.className.search(/idx_dir/) > -1){
                frm.elements['ns'].value = acl.hsc(acl.parseatt(e.target.search)['ns']);
                frm.elements['id'].value = '';
            }

            acl.loadinfo();
        }

        e.stopPropagation();
        e.preventDefault();
        return false;
    }

};

addInitEvent(acl.init);


/* XXXXXXXXXX end of /export1/data/dokuwiki/vlhc_dokuwiki-2009-02-14/lib/exe/../../lib/plugins/acl/script.js XXXXXXXXXX */

addInitEvent(function(){ scrollToMarker(); });
addInitEvent(function(){ focusMarker(); });

