
// ===================================================================================
//  js_geber_lib
// ===================================================================================

var geber_lib_onloadFuncArray;

function geber_lib_addLoadEvent(func) 
{
    if (document.all)
    {
        try { attachEvent("onload", func); return;}
        catch (e) 
        { }
    }
    else
    {
        window.addEventListener("load", func, true);
        return;
    }


/*
   // special case for IE on Mac. Ignore all others
   var agt = navigator.userAgent.toLowerCase();
   if ((agt.indexOf("mac") < 0) || (agt.indexOf("opera") >= 0) || (agt.indexOf("msie") < 0))
   {

       window.onload = func;
       return;
   }
*/

  // initialise the onload handler
  if (geber_lib_onloadFuncArray == null)
  {
      geber_lib_onloadFuncArray = new Array();

      var oldonload = window.onload;
      window.onload = function() 
      {
          for (var funcIdx=0; funcIdx <  geber_lib_onloadFuncArray.length; funcIdx++)
               geber_lib_onloadFuncArray[funcIdx]();
      }
  }

  geber_lib_onloadFuncArray[geber_lib_onloadFuncArray.length] = func;
}




   // geber_lib_stripTags
   // ---------------------------------------------------------------------------------------------------------------------------------------------------------
   /**
    * stripps all the tags from the provided text
    */
    function geber_lib_stripTags(text)
    {
        if (!text || (typeof text != "string") || (text.length <= 0)) 
            return "";

        // strip off all javascript tags
        text = text.replace(/<script.*<\/script[^>]*>/, "");


        // strip off all stye tags
        text = text.replace(/<style.*<\/style[^>]*>/, "");

        // strip off all other tags
        text = text.replace(/<[^>]*>/, "");

        // strip off all invalid characters
        text = text.replace(/[-\w+|"'\.]/, "");

        return text;
    }


    function geber_lib_Numsort(a,b)
    { return a-b; }


function geber_lib_getQueryParameter(paramName)
{
       var query = window.location.search.toString();

       if (!query || (query.length <= 0)) 
           return "";

       if ((paramName == null) || (typeof(paramName) != "string") || (paramName.length <= 0))
         paramName = "q";

       query = query.match(new RegExp("^(.*[?&])?" + paramName + "=(.*)$"));
       if (!query) return "";

       query = query[2];
     
       // remove the trailing parameters that are not part of this queryparam
       var nextParamIdx = query.indexOf("&");
       while (nextParamIdx >= 0)
       {
           // this is no parameter delimiter in case "&amp;" has been found
           if ((query.length > (nextParamIdx+4)) && (query.substring(nextParamIdx, nextParamIdx+4).toLowerCase() == "&amp"))
               nextParamIdx = query.indexOf("&", nextParamIdx+4)
           else
           {
               query = query.substring(0, nextParamIdx);
               nextParamIdx = -1;
           }
       }

       // clean up the query string
       query = unescape(query);
       query = geber_lib_stripTags(query);
       query = query.replace(/[^-_:;,\w\/\.=]/, "");
       return query;
}


function geber_lib_writeDocument(htmlText)
{
    document.write(htmlText);
}


function print_setImg() {   
    var a = document.getElementById("mainbar");
    for(var i = 0; i < a.getElementsByTagName("img").length; i++) {
      if (document.formular.setImg[0].checked) 
        a.getElementsByTagName("img")[i].style.display="inline";
      if (document.formular.setImg[1].checked) 
        a.getElementsByTagName("img")[i].style.display="none";
    }
  }

function print_hideLinks() {
    // resize print window
    try {resizePrintPopUp();} catch(e) {}

    var mainbar = document.getElementById("mainbar");
    var docLinks = mainbar.getElementsByTagName("a");
    for (var i=0; i<docLinks.length; i++) {
      docLinks[i].href="#";
    }
  }




function onLoadSetBaseURLParameters(pagePath)
{

    var siemensNixdorfBasePath = "http://www.wincor-nixdorf.com/static/finanzberichte/2006-2007/q1";

    // *** set the sendthispage base URL to the proper URL of this page
    var sendthispageElem = document.getElementById("sendthispage");
    if (sendthispageElem && !window.location.protocol.match(/^File/i)) {
    	  var siemensNixdorfBasePathRegEx  = siemensNixdorfBasePath.replace(/\//g, "\\/");
        eval("sendthispageElem.href = sendthispageElem.href.replace(/" + siemensNixdorfBasePathRegEx + "[^&]*/, window.location.href);" );
    }


    // *** calculate base URL path of the page    
    var basePath = String(window.location.href);
    basePath = basePath.replace(/\.html?/, "");
    
    if (pagePath && (typeof(pagePath) == "string") && pagePath != "/") {
    	  pagePath = pagePath.replace(/^\s+/, "");
    	  pagePath = pagePath.replace(/\s+$/, "");
    	  pagePath = pagePath.replace(/\//g, "\\/")
        eval("basePath = basePath.replace(/" + pagePath + "/gi, \"\");");
    }
    
    // *** set the search parameter
    var searchPathParam = document.getElementById("searchBaseDir");
    if (searchPathParam && basePath && basePath.length > 0) {
    	  searchPathParam.value = basePath;
    }   
}


function onSubmitSearch(searchForm)
{

  if (window.location.href.match(/iedit.geber.at/))
    return;
    
  var w = 700;
  var h = 430;
  
  /* increase size because status bar is always visible on Windows XP */
  var Ergebnis = navigator.userAgent.match(/Windows NT ([5-9]).([0-9])/);
  if (navigator.userAgent.match(/ MSIE/) && Ergebnis && Ergebnis[2] && Ergebnis[1] && ((Ergebnis[2] >= 1) || (Ergebnis[2] > 5))) 
    h = h+10;

  // redirect target of the search form to it
  if (searchForm)
  {
      try {
          var targetWindowName = "searchresultpopup" + String(Math.round(Math.random()*99999));

          try { searchForm.target = targetWindowName; }
          catch (ex) {}

          if (searchForm.target.charAt(0) != "_")
          {
              var popUpWindow = window.open('', searchForm.target, 'resizable=yes, status=no, toolbar=no, scrollbars, width='+w+', height='+h);
              popUpWindow.resizeTo(w, h);
              popUpWindow.focus();
          }
      } catch (e) {}
  }

}

var operabar = (window.opera ? "=yes" : "");

function sendPopUp(newLocation) {
  var w = 570;
  var h = 540;
 	
  return PopUpOpenWindow(newLocation, 'popup', 'resizable=yes, status=no, toolbar=no, scrollbars' + operabar, w, h); 
}

function printPopUp(newLocation) {
  var w = 666;
  var h = 560;
  
  var operabar = "";
  if (window.opera) operabar = "=yes";
  
   return PopUpOpenWindow(newLocation, 'popup', 'resizable=yes, status=no, toolbar=no, scrollbars' + operabar, w, h); 
}

function resizePrintPopUp() {
  var w = 666;
  var h = 560;

  h = h + 15;
  if (opener)
      window.resizeTo(w, h);
}

function glossaryPopUp(newLocation) {
  var h = 350;
  var w = 500;
 
  return PopUpOpenWindow(newLocation, 'glossary', 'resizable=yes, status=no, toolbar=no, scrollbars' + operabar, w, h);
}


function tablePopUp(newLocation, preferedWidth) {

  var w = (preferedWidth && !isNaN(preferedWidth))? preferedWidth : 800;
  var h = 500;

  return PopUpOpenWindow(newLocation, 'tablePopUp', 'scrollbars,resizable=yes,location=no,status=no,toolbar=no,', w, h);
}

function imagePopUp(newLocation, w, h) 
{
  w += 15;
  h += 32;
   return PopUpOpenWindow(newLocation, 'imagePopUp', 'resizable=yes,location=no,status=no,toolbar=no,', w, h);
}

function PopUpOpenWindow(newLocation, name, specialFeatures, w, h)
{
  var popUpWindow;

  /* increase size because status bar is always visible on Windows XP */
  h = h + 15;


  try
  {
    popUpWindow = window.open(newLocation, name, specialFeatures, width='+w+', height='+h');
  }
  catch (e)
  {
    return false;
  }  
  
  try
  {
    popUpWindow.resizeTo(w, h);
  }
  catch (e) {}
  
  try
  {
    popUpWindow.focus();
  }
  catch (e) {}

  return true;

}
// ===================================================================================
//  js_highlightsearch
// ===================================================================================

function geberClass_GSearchHighlight()
{
    this.contentElementIDs = new Array('headerContent', 'searchTop5', 'bodyContent');
    this.contentElementNoHitMarkerID = new Array('searchNoHits');
    this.lastIDIfFound = "searchTop5";
    this.searchQueryParamName = "q";
}


/*
 */
geberClass_GSearchHighlight.prototype.addHighlighting = function()
{
    var searchPhrases = this.prepareSearchData();
    if (!searchPhrases || searchPhrases.length <= 0)
        return;

    // if a no search hit marker exists, do not highlight anything
    if (this.contentElementNoHitMarkerID && this.contentElementNoHitMarkerID.length > 0)
    {
        for (var k=0; k < this.contentElementNoHitMarkerID.length; k++)
        {
            var noSearchHit = document.getElementById(this.contentElementNoHitMarkerID[k]);
            if (noSearchHit)
                return;
        }
    }

    // only IE style of reading HTML content is supported
    if (!document.body || typeof(document.body.innerHTML) == "undefined")
        return;


    var max=10;
    for (var layerIdx=0; layerIdx < this.contentElementIDs.length && max > 0; layerIdx++, max--)
    {
        var contentElem = document.getElementById(this.contentElementIDs[layerIdx]);
        if (contentElem && contentElem.innerHTML)
        {
            var bodyText = contentElem.innerHTML;
            for (var pIdx=0; pIdx < searchPhrases.length; pIdx++)
            {
                bodyText = this.addHighlightingForTerm(bodyText, searchPhrases[pIdx]);
            }
            contentElem.innerHTML = bodyText;
        }
    }

}




/*
 * This is the function that actually highlights a text string by
 * adding HTML tags before and after all occurrences of the search
 * term. You can pass your own tags if you'd like, or if the
 * highlightStartTag or highlightEndTag parameters are omitted or
 * are empty strings then the default <font> tags will be used.
 */
geberClass_GSearchHighlight.prototype.addHighlightingForTerm = function(bodyText, searchTermRegEx, highlightStartTag, highlightEndTag)
{
    if (!bodyText || typeof(bodyText) != "string" || bodyText.length <= 0)
        return "";

    if (!searchTermRegEx || typeof(searchTermRegEx) != "string" || searchTermRegEx.length <= 0)
        return bodyText;

    // the highlightStartTag and highlightEndTag parameters are optional
    if ((!highlightStartTag) || (!highlightEndTag))
    {
        highlightStartTag = "<span class=\"se_hilite\">" ;
        highlightEndTag = "</span>" ;
    }

    bodyText = this.decodeEntities(bodyText);
    bodyText = this.encodeEntities(bodyText);
    bodyText = bodyText.replace(new RegExp(searchTermRegEx, "gi"), highlightStartTag + "$1" + highlightEndTag);

    // remove all higlighting within tags
    bodyText = bodyText.replace(new RegExp("(<[^>]*)" + highlightStartTag + "([^>]*)" + highlightEndTag  + "([^>]*>)", "gi"), "$1$2$3");
    bodyText = bodyText.replace(new RegExp("(<[^>]*)" + highlightStartTag + "([^>]*>)", "gi"), "$1$2");
    bodyText = bodyText.replace(new RegExp("(<[^>]*)" + highlightEndTag + "([^>]*>)", "gi"), "$1$2");

    // return the result
    return bodyText;
}



/***
 * reads the search query from the document and returns an
 * array search terms that have to be highlighted in the text.
 */
geberClass_GSearchHighlight.prototype.prepareSearchData = function()
{
   var resultingSearchTerms = new Array();

    // get the decoded search query
    var searchText = this.getSearchQuery() ;
    if (searchText != null && searchText != "")
    {
        // decode quotes
        searchText = searchText.replace(/(%22|(&(amp;)?|%26)quot;|(&(amp;)?|%26)(#|%23)22;|(&(amp;)?|%26)(#|%23)x16;)/, '"');

        // extract all quoted exact matches
        var pos1 = searchText.indexOf('"');
        var pos2 = -1;
        if (pos1 >= 0 && pos1 < searchText.length)
            pos2 = searchText.indexOf('"', pos1);


        while (pos1 >= 0 && pos2 >= 0 && pos1 < pos2)
        {
            if (pos2 - pos1 >= 2)
            {
                // get the quoted text
                var quotedTerm = searchText.substring(pos1, pos2+1);
                quotedTerm = quotedTerm.substring(1, quotedTerm.length - 2);
                resultingSearchTerms[resultingSearchTerms.length] = quotedTerm;
            }

            // remove the quoted string from the search term
            searchText = searchText.substring(0, pos1) + searchText.substring(pos2+1, searchText.length);
        }
    }
    else
        return false;


    // now stripp of some unwanted characters that are only valid inside quoted texts
    searchText = this.cleanSearchQuery(searchText);

    // split the search text into separate words
    var words = searchText.split(" ");

    // add the words to the resulting search term
    for (var i=0; words && i<words.length; i++)
    {
        if (words && words.length > 0)
            resultingSearchTerms[resultingSearchTerms.length] = words[i];
    }


    // convert every search term to a regular expression string
    for (var j=0; j<resultingSearchTerms.length; j++)
    {
        var regexString = resultingSearchTerms[j];
        regexString = this.decodeEntities(regexString);

        // encode HTML special entities
        regexString = regexString.replace(/&/g, "(&|&amp;|&#38;|&#x26;)");
        regexString = regexString.replace(/</g, "(<|&lt;|&#60;|&#x3[cC];)");
        regexString = regexString.replace(/>/g, "(>|&gt;|&#62;|&#x3[eE];)");
        regexString = regexString.replace(/"/g, "(\"|&quot;|&#34;|&#x22;)");

        regexString = this.encodeEntities(regexString);

        regexString = "(" + regexString.replace(/\s+/gi, "(\\s+|<[^>]*>)") + ")";
        resultingSearchTerms[j] = regexString;

    }

    return resultingSearchTerms;
}


/**
 * Deletes extra chars that are not valid with the search terms
 *
 * Abbr.: + - 'and', '-' - not, '|' - or
 *
 * Conversion rules:
 *  +- = -, -| = |, +| = |
 *
 * @param str - string to format
 */
geberClass_GSearchHighlight.prototype.cleanSearchQuery = function(str)
{
    // validate param
    if (str && str != null && str != "")
    {

        // strip quotes
        str = str.replace(/["']/g, '') ;

        // delete repeated control chars
        str = str.replace(/[-+|!\s]+/g, ' ') ;

        // strip off whitespace characters
        var re = new RegExp("[" + String.fromCharCode(0) + "-" + String.fromCharCode(47)  + ":;<>=?@\\[\\]\\\\^" +
                                   String.fromCharCode(96) +
                                   String.fromCharCode(123) + "-" + String.fromCharCode(160)  + "]", "gi") ;
        re.global = true ;
        str = str.replace(re, ' ') ;

        // strip extra spaces
        str = str.replace(/\s+/g, ' ') ;
    }

    return str ;
}


/**
 * Parses URI and returns back only search entry
 */
geberClass_GSearchHighlight.prototype.getSearchQuery = function()
{
    var searchQuery = "" ;


    // validate search_token
    if (!this.searchQueryParamName)
        this.searchQueryParamName = "q";

    // get the query
    var queryParamRegEx = new RegExp("^.*[?&]" + this.searchQueryParamName + "=(.*)$");
    var matches = String(document.location.search).match(queryParamRegEx);
    if (!matches || matches.length <= 0 || !matches[1] || matches[1].length <= 0)
    {
        return searchQuery;
    }

    searchQuery = matches[1];

    searchQuery = unescape(searchQuery);

    // decode the entities
    searchQuery = this.decodeEntities(searchQuery);

    // get rid of invalid whitespace characters
    searchQuery = searchQuery.replace(/[\r\n\t]+/gi, ' ') ;
    var re = new RegExp("[" + String.fromCharCode(0) + "-" + String.fromCharCode(31)  +
                                   String.fromCharCode(96) + "]", "gi") ;
    re.global = true ;
    searchQuery = searchQuery.replace(re, '') ;

    // convert fixed size space
    re = new RegExp(String.fromCharCode(160) + "+", "gi") ;
    searchQuery = searchQuery.replace(re, ' ') ;

    // strip off extra query paramaters
    searchQuery = searchQuery.replace(/&(amp;)?([^;]*=.*)?$/gi, "");

    // tags are invalid
    if (searchQuery.match(/<.?(script|style)/gi))
        return "";

    // remove tags
    searchQuery = searchQuery.replace(/<script.*<.script[^>]*>/gi, "");
    searchQuery = searchQuery.replace(/<style.*<.style[^>]*>/gi, "");
    searchQuery = searchQuery.replace(/<[^>]*>/gi, "");

    return searchQuery ;
}

/**
 * decodes HTML entities
 */
geberClass_GSearchHighlight.prototype.decodeEntities = function(text)
{

    if (!text || text == null || typeof(text) != "string" || text.length <= 0)
        return "";

    var entities = this.getHTMLDecodeEntities();
    for (var i in entities)
    {
        var charCode = parseInt(i.substr(1));
        if (isNaN(charCode)) continue;

        var entityRegEx = entities[i].replace(/&/, "&([aA][mM][pP];)?");
        var regexString = "(&([aA][mM][pP];)?#" + charCode + ";|" + entityRegEx  + "|&([aA][mM][pP];)?#x" + Number(charCode).toString(16) + ";)";
        var re = new RegExp(regexString, "g");
        re.global = true ;
        text = text.replace(re, String.fromCharCode(charCode));
    }


    // prepare other unicode replacement
    text = text.replace(/&amp;(#x?[0-9a-fA-F]+;)/gi, "&$1");


    // decode other unicode characters
    var unicodeRegEx = new RegExp(/&#([0-9]+|x[0-9a-fA-F]+);/);
    var foundUnicodeChar = text.match(unicodeRegEx);
    while (foundUnicodeChar && foundUnicodeChar.length >= 2 && foundUnicodeChar[1] && foundUnicodeChar[1].length > 0)
    {
        var charCodeString = foundUnicodeChar[1];
        var charCode = -1;
        var replacementChar = "";

        if (charCodeString.charAt(0) == "x")
            charCode = parseInt(charCodeString.substr(1), "16");
        else
            charCode = parseInt(charCodeString);

        if (!isNaN(charCode) && (charCode > 255))
            replacementChar = String.fromCharCode(charCode);

        text = text.replace(new RegExp("&#" + charCodeString + ";", "gi"), replacementChar);
        foundUnicodeChar = text.match(unicodeRegEx);
    }


    // decode special Win 1252 characters
    text = text.replace(/&#(128|x80);/gi, String.fromCharCode(8364));
    text = text.replace(/&#(130|x82);/gi, String.fromCharCode(8218));
    text = text.replace(/&#(132|x84);/gi, String.fromCharCode(8222));
    text = text.replace(/&#(133|x85);/gi, String.fromCharCode(8230));
    text = text.replace(/&#(134|x86);/gi, String.fromCharCode(8224));
    text = text.replace(/&#(135|x87);/gi, String.fromCharCode(8225));
    text = text.replace(/&#(137|x89);/gi, String.fromCharCode(8240));
    text = text.replace(/&#(139|x8B);/gi, String.fromCharCode(8249));

    return text;
}


/**
 * encode HTML entities
 */
geberClass_GSearchHighlight.prototype.encodeEntities = function(text)
{
    if (!text || text == null || typeof(text) != "string" || text.length <= 0)
        return "";

    var entities = this.getHTMLEncodeEntities();

    // encode other unicode characters
    var newText = "";
    for (var i=0; i<text.length; i++)
    {
        var cc = text.charCodeAt(i);
        var c = text.charAt(i);
        // remove invalid character
        if (cc == 0)
            continue;
        else if (entities["i" + cc])
            newText += entities["i" + cc];
        else if (cc <= 127)
            newText += c;
        else
            newText += "&#x" + Number(cc).toString(16) + ";";
    }


    return newText;
}

geberClass_GSearchHighlight.prototype.getHTMLEncodeEntities = function()
{
    var entities = this.getHTMLDecodeEntities();;

    // Win 1252 character set
    entities["i128"] = "&euro;";
    entities["i130"] = "&sbquo;";
    entities["i132"] = "&bdquo;";
    entities["i133"] = "&hellip;";
    entities["i134"] = "&dagger;";
    entities["i135"] = "&Dagger;";
    entities["i137"] = "&permil;";
    entities["i139"] = "&lsaquo;";

    return entities;
}


geberClass_GSearchHighlight.prototype.getHTMLDecodeEntities = function()
{
    var entities = new Object();

              // unicode
    entities["i145"] = "&lsquo;";
    entities["i146"] = "&rsquo;";
    entities["i147"] = "&ldquo;";
    entities["i148"] = "&rdquo;";
    entities["i149"] = "&bull;";
    entities["i150"] = "&ndash;";
    entities["i151"] = "&mdash;";
    entities["i153"] = "&trade;";
    entities["i155"] = "&rsaquo;";
    entities["i160"] = "&nbsp;";
    entities["i161"] = "&iexcl;";
    entities["i162"] = "&cent;";
    entities["i163"] = "&pound;";
    entities["i164"] = "&curren;";
    entities["i165"] = "&yen;";
    entities["i166"] = "&brvbar;";
    entities["i167"] = "&sect;";
    entities["i168"] = "&uml;";
    entities["i169"] = "&copy;";
    entities["i170"] = "&ordf;";
    entities["i171"] = "&laquo;";
    entities["i172"] = "&not;";
    entities["i173"] = "&shy;";
    entities["i174"] = "&reg;";
    entities["i175"] = "&macr;";
    entities["i176"] = "&deg;";
    entities["i177"] = "&plusmn;";
    entities["i178"] = "&sup2;";
    entities["i179"] = "&sup3;";
    entities["i180"] = "&acute;";
    entities["i181"] = "&micro;";
    entities["i182"] = "&para;";
    entities["i183"] = "&middot;";
    entities["i184"] = "&cedil;";
    entities["i185"] = "&sup1;";
    entities["i186"] = "&ordm;";
    entities["i187"] = "&raquo;";
    entities["i188"] = "&frac14;";
    entities["i189"] = "&frac12;";
    entities["i190"] = "&frac34;";
    entities["i191"] = "&iquest;";
    entities["i192"] = "&Agrave;";
    entities["i193"] = "&Aacute;";
    entities["i194"] = "&Acirc;";
    entities["i195"] = "&Atilde;";
    entities["i196"] = "&Auml;";
    entities["i197"] = "&Aring;";
    entities["i198"] = "&AElig;";
    entities["i199"] = "&Ccedil;";
    entities["i200"] = "&Egrave;";
    entities["i201"] = "&Eacute;";
    entities["i202"] = "&Ecirc;";
    entities["i203"] = "&Euml;";
    entities["i204"] = "&Igrave;";
    entities["i205"] = "&Iacute;";
    entities["i206"] = "&Icirc;";
    entities["i207"] = "&Iuml;";
    entities["i208"] = "&ETH;";
    entities["i209"] = "&Ntilde;";
    entities["i210"] = "&Ograve;";
    entities["i211"] = "&Oacute;";
    entities["i212"] = "&Ocirc;";
    entities["i213"] = "&Otilde;";
    entities["i214"] = "&Ouml;";
    entities["i215"] = "&times;";
    entities["i216"] = "&Oslash;";
    entities["i217"] = "&Ugrave;";
    entities["i218"] = "&Uacute;";
    entities["i219"] = "&Ucirc;";
    entities["i220"] = "&Uuml;";
    entities["i221"] = "&Yacute;";
    entities["i222"] = "&THORN;";
    entities["i223"] = "&szlig;";
    entities["i224"] = "&agrave;";
    entities["i225"] = "&aacute;";
    entities["i226"] = "&acirc;";
    entities["i227"] = "&atilde;";
    entities["i228"] = "&auml;";
    entities["i229"] = "&aring;";
    entities["i230"] = "&aelig;";
    entities["i231"] = "&ccedil;";
    entities["i232"] = "&egrave;";
    entities["i233"] = "&eacute;";
    entities["i234"] = "&ecirc;";
    entities["i235"] = "&euml;";
    entities["i236"] = "&igrave;";
    entities["i237"] = "&iacute;";
    entities["i238"] = "&icirc;";
    entities["i239"] = "&iuml;";
    entities["i240"] = "&eth;";
    entities["i241"] = "&ntilde;";
    entities["i242"] = "&ograve;";
    entities["i243"] = "&oacute;";
    entities["i244"] = "&ocirc;";
    entities["i245"] = "&otilde;";
    entities["i246"] = "&ouml;";
    entities["i247"] = "&divide;";
    entities["i248"] = "&oslash;";
    entities["i249"] = "&ugrave;";
    entities["i250"] = "&uacute;";
    entities["i251"] = "&ucirc;";
    entities["i252"] = "&uuml;";
    entities["i253"] = "&yacute;";
    entities["i254"] = "&thorn;";
    entities["i255"] = "&yuml;";

    entities["i338"] = "&OElig;";
    entities["i339"] = "&oelig;";
    entities["i352"] = "&Scaron;";
    entities["i353"] = "&scaron;";
    entities["i376"] = "&Yuml;";
    entities["i402"] = "&fnof;";
    entities["i710"] = "&circ;";
    entities["i732"] = "&tilde;";
    entities["i913"] = "&Alpha;";
    entities["i914"] = "&Beta;";
    entities["i915"] = "&Gamma;";
    entities["i916"] = "&Delta;";
    entities["i917"] = "&Epsilon;";
    entities["i918"] = "&Zeta;";
    entities["i919"] = "&Eta;";
    entities["i920"] = "&Theta;";
    entities["i921"] = "&Iota;";
    entities["i922"] = "&Kappa;";
    entities["i923"] = "&Lambda;";
    entities["i924"] = "&Mu;";
    entities["i925"] = "&Nu;";
    entities["i926"] = "&Xi;";
    entities["i927"] = "&Omicron;";
    entities["i928"] = "&Pi;";
    entities["i929"] = "&Rho;";
    entities["i931"] = "&Sigma;";
    entities["i932"] = "&Tau;";
    entities["i933"] = "&Upsilon;";
    entities["i934"] = "&Phi;";
    entities["i935"] = "&Chi;";
    entities["i936"] = "&Psi;";
    entities["i937"] = "&Omega;";
    entities["i945"] = "&alpha;";
    entities["i946"] = "&beta;";
    entities["i947"] = "&gamma;";
    entities["i948"] = "&delta;";
    entities["i949"] = "&epsilon;";
    entities["i950"] = "&zeta;";
    entities["i951"] = "&eta;";
    entities["i952"] = "&theta;";
    entities["i953"] = "&iota;";
    entities["i954"] = "&kappa;";
    entities["i955"] = "&lambda;";
    entities["i956"] = "&mu;";
    entities["i957"] = "&nu;";
    entities["i958"] = "&xi;";
    entities["i959"] = "&omicron;";
    entities["i960"] = "&pi;";
    entities["i961"] = "&rho;";
    entities["i962"] = "&sigmaf;";
    entities["i963"] = "&sigma;";
    entities["i964"] = "&tau;";
    entities["i965"] = "&upsilon;";
    entities["i966"] = "&phi;";
    entities["i967"] = "&chi;";
    entities["i968"] = "&psi;";
    entities["i969"] = "&omega;";
    entities["i977"] = "&thetasym;";
    entities["i978"] = "&upsih;";
    entities["i982"] = "&piv;";
    entities["i8194"] = "&ensp;";
    entities["i8195"] = "&emsp;";
    entities["i8201"] = "&thinsp;";
    entities["i8204"] = "&zwnj;";
    entities["i8205"] = "&zwj;";
    entities["i8206"] = "&lrm;";
    entities["i8207"] = "&rlm;";
    entities["i8211"] = "&ndash;";
    entities["i8212"] = "&mdash;";
    entities["i8216"] = "&lsquo;";
    entities["i8217"] = "&rsquo;";
    entities["i8218"] = "&sbquo;";
    entities["i8220"] = "&ldquo;";
    entities["i8221"] = "&rdquo;";
    entities["i8222"] = "&bdquo;";
    entities["i8224"] = "&dagger;";
    entities["i8225"] = "&Dagger;";
    entities["i8226"] = "&bull;";
    entities["i8230"] = "&hellip;";
    entities["i8240"] = "&permil;";
    entities["i8242"] = "&prime;";
    entities["i8243"] = "&Prime;";
    entities["i8249"] = "&lsaquo;";
    entities["i8250"] = "&rsaquo;";
    entities["i8254"] = "&oline;";
    entities["i8260"] = "&frasl;";
    entities["i8364"] = "&euro;";
    entities["i8465"] = "&image;";
    entities["i8472"] = "&weierp;";
    entities["i8476"] = "&real;";
    entities["i8482"] = "&trade;";
    entities["i8501"] = "&alefsym;";
    entities["i8592"] = "&larr;";
    entities["i8593"] = "&uarr;";
    entities["i8594"] = "&rarr;";
    entities["i8595"] = "&darr;";
    entities["i8596"] = "&harr;";
    entities["i8629"] = "&crarr;";
    entities["i8656"] = "&lArr;";
    entities["i8657"] = "&uArr;";
    entities["i8658"] = "&rArr;";
    entities["i8659"] = "&dArr;";
    entities["i8660"] = "&hArr;";
    entities["i8704"] = "&forall;";
    entities["i8706"] = "&part;";
    entities["i8707"] = "&exist;";
    entities["i8709"] = "&empty;";
    entities["i8711"] = "&nabla;";
    entities["i8712"] = "&isin;";
    entities["i8713"] = "&notin;";
    entities["i8715"] = "&ni;";
    entities["i8719"] = "&prod;";
    entities["i8721"] = "&sum;";
    entities["i8722"] = "&minus;";
    entities["i8727"] = "&lowast;";
    entities["i8730"] = "&radic;";
    entities["i8733"] = "&prop;";
    entities["i8734"] = "&infin;";
    entities["i8736"] = "&ang;";
    entities["i8743"] = "&and;";
    entities["i8744"] = "&or;";
    entities["i8745"] = "&cap;";
    entities["i8746"] = "&cup;";
    entities["i8747"] = "&int;";
    entities["i8756"] = "&there4;";
    entities["i8764"] = "&sim;";
    entities["i8773"] = "&cong;";
    entities["i8776"] = "&asymp;";
    entities["i8800"] = "&ne;";
    entities["i8801"] = "&equiv;";
    entities["i8804"] = "&le;";
    entities["i8805"] = "&ge;";
    entities["i8834"] = "&sub;";
    entities["i8835"] = "&sup;";
    entities["i8836"] = "&nsub;";
    entities["i8838"] = "&sube;";
    entities["i8839"] = "&supe;";
    entities["i8853"] = "&oplus;";
    entities["i8855"] = "&otimes;";
    entities["i8869"] = "&perp;";
    entities["i8901"] = "&sdot;";
    entities["i8968"] = "&lceil;";
    entities["i8969"] = "&rceil;";
    entities["i8970"] = "&lfloor;";
    entities["i8971"] = "&rfloor;";
    entities["i9001"] = "&lang;";
    entities["i9002"] = "&rang;";
    entities["i9674"] = "&loz;";
    entities["i9824"] = "&spades;";
    entities["i9827"] = "&clubs;";
    entities["i9829"] = "&hearts;";
    entities["i9830"] = "&diams;";

    return entities;
}


function performSearchHighlight()
{
    var highlighter = new geberClass_GSearchHighlight();
    highlighter.addHighlighting();
}

geber_lib_addLoadEvent(performSearchHighlight);


// -----------------------------------------------------------------------------------------------
// statistics
// -----------------------------------------------------------------------------------------------

function geber_preLoadGWSImage(simple)
{
    if (!simple)
        window.setTimeout("geber_doPreLoadGWSImage(false)", 100);
    else
        window.setTimeout("geber_doPreLoadGWSImage(true)", 100);

}

function geber_doPreLoadGWSImage(simple)
{
    var pageURL = escape(window.location);

    var donotgws = pageURL;
    var Ergebnis = donotgws.search(/laut.iedit.geber.at./);
    if (Ergebnis != -1)
          return;


    var referrer = document["referrer"]==null?'':escape(document.referrer);
    var imageURL = "http://gws.geber.at/wincor/gws.gif?ref=" +
                  referrer + "&pg=" + pageURL;

    imageURL += "&screen=" + screen.width + "x" + screen.height;
    var myImg = new Image();
    myImg.src = imageURL;
}

