/* START - OLD addevent.js */
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('6 f(a,b,c){2(a.n){a.n(b,c,7)}g 2(a.j){a.j("8"+b,c)}g{2(!c.$$5)c.$$5=f.5++;2(!a.4)a.4={};9 d=a.4[b];2(!d){d=a.4[b]={};2(a["8"+b]){d[0]=a["8"+b]}}d[c.$$5]=c;a["8"+b]=e}};f.5=1;6 v(a,b,c){2(a.k){a.k(b,c,7)}g{2(a.4&&a.4[b]){t a.4[b][c.$$5]}}};6 e(a){9 b=m;a=a||h(((3.s||3.r||3).q||p).o);9 c=3.4[a.u];A(9 i y c){3.$$e=c[i];2(3.$$e(a)===7){b=7}}l b};6 h(a){a.x=6(){3.w=7};a.z=6(){3.B=m};l a};',38,38,'||if|this|events|guid|function|false|on|var|||||handleEvent|addEvent|else|fixEvent||attachEvent|removeEventListener|return|true|addEventListener|event|window|parentWindow|document|ownerDocument|delete|type|removeEvent|returnValue|preventDefault|in|stopPropagation|for|cancelBubble'.split('|'),0,{}))
/* END - OLD addevent.js */

/* START - OLD general.js */
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('7 8=\'\';4 12(a){2(8!=\'\'&&8!=a)3.q(8);3.q(a);2(8!=a)8=a;F 8=\'\';5 n}4 U(a,b,c,d,e,f){H(i=0;i<b.k;i++){3.r(b[i]);s=D(f+"T"+b[i]);2(s)s.B=e}c.B=d;3.m(a);5 n}4 D(a){2(g&&g.w){u=g.w(a);2(u)5 u}}4 16(a,b,c){2(c){2(a.o==b)a.o=\'\'}F{2(a.o==\'\')a.o=b}}7 p=[];4 J(a){14(p.k>0)I(p.13())}4 v(a){2(a&&(6 a.G!="9")&&(a.G.11()=="10"))a=a.E;7 b=a.E.Y(\'X\');2(b&&b.k)5 b[0];5 a}4 W(a){7 b=l;2((a==V)||(6 a.C=="S")){a=R(((l.Q||l.g||l).P||O).N);b=a.C}J(a);7 c=v(b);2(c){c.j.h=\'M\';p.A(b);a.L()}a.Z();5 n}4 I(a){2(a){7 b=v(a);2(b)b.j.h=\'y\'}5 n}2(6 $=="9"){4 $(a){2(t.k>1){H(7 i=0,x=[],K=t.k;i<K;i++)x.A($(t[i]));5 x}2(6 a==\'15\')a=g.w(a);5 a}}2(6 3=="9"){3={}}2(6 3.r=="9"){3.r=4(a){$(a).j.h=\'y\';5 a}}2(6 3.m=="9"){3.m=4(a){$(a).j.h=\'\';5 a}}2(6 3.z=="9"){3.z=4(a){5 $(a).j.h!=\'y\'}}2(6 3.q=="9"){3.q=4(a){a=$(a);3[3.z(a)?\'r\':\'m\'](a);5 a}}',62,69,'||if|Element|function|return|typeof|var|activePhonemenuID|undefined|||||||document|display||style|length|this|show|false|value|formHelpButtonsOpen|toggle|hide|aTabLi|arguments|aRef|associatedHelpTextFor|getElementById|elements|none|visible|push|className|srcElement|getRef|parentNode|else|nodeName|for|hideAssociatedHelpText|clearAssociatedHelpTexts|len|stopPropagation|block|event|window|parentWindow|ownerDocument|fixEvent|object|_|selectTab|null|doFormHelpButtonClick|span|getElementsByTagName|preventDefault|img|toLowerCase|togglePhoneMenu|pop|while|string|switchFocusText'.split('|'),0,{}))
/* END - OLD general.js */

/* START - OLD events.js*/
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('5 t(){3(1.2&&1.7&&1.2!=\'\'&&1.2==1.7)1.2=\'\';n C};5 z(){3(1.7&&1.2==\'\'&&1.7!=\'\')1.2=1.7;n C};5 y(a){3((a==f)&&(g.G!=f))a=g.G;3(a.1i==13)1.1a.N()};5 M(){k a=f;3(a=8.x("11")){B(i=0;i<a.H.q;i++){o=a.H[i];3(o.Y=="1h"){o.1g=5(){1.A+=" S"};o.19=5(){1.A=1.A.l(" S","")}}}}3(a=8.x("O")){a.17=5(){g.O()}}3(a=8.x("16")){a.14=5(){3(9 L=="5")n L(1);3(1.4&&1.6&&1.d&&1.w&&1.K){3(1.4.2!=\'\'&&1.6.2!=\'\'){3(1.h!=f&&1.h.u)J(\'E\',1.4.2,I*s*s*10*Z);r J(\'E\',\'\',I*s);1.d.2=1.d.2.l(\'%m%e\',\'%m%e\'+1.4.2)+\'&4=\'+1.4.2;1.w.2=1.w.2.l(\'%m%e\',\'%m%e\'+1.4.2)+\'&4=\'+1.4.2;3(8.j!=p){B(i=0;i<8.j.v.q;i++){3(8.j.v[i].u){1.d.2=1.d.2.l(F(\'%V%U\'),F(\'%V%U%1f%1e%1d%e\'+8.j.v[i].2))}}}1.N()}r{1c(1.K.2)}n 1b}};3(a.4&&a.h){k b=18(\'E\');3((b!=f)&&(b!=\'\')){a.4.2=b;a.h.u=C;a.6.2="";a.6.Q=y}r{3(9 a.4.7=="p")a.4.7=a.4.2;a.4.P=t;a.4.R=z;3(9 a.6.7=="p")a.6.7=a.6.2;a.6.Q=y;a.6.P=t;a.6.R=z}}}3((9 X=="5")&&(9 D=="5")&&(9 T=="5")){k c=X(8,"a","15");B(k i=0,W=c.q;i<W;i++)D(c[i],"12",T)}};D(g,"1j",M);',62,82,'|this|value|if|usr_name|function|usr_password|defaultValue|document|typeof||||HiddenURI|3D|null|window|saveusername||serviceForm|var|replace|26usr_name|return|node|undefined|length|else|60|doFocus|checked|elements|RedirectOnFailure|getElementById|doSubmitOnEnter|doBlur|className|for|true|addEvent|loginusername|escape|event|childNodes|1000|setCookie|onErrorMessage|checkLoginForm|startList|submit|print|onfocus|onkeypress|onblur|over|doFormHelpButtonClick|3D1801351|26formelement|len|getElementsByClassName|nodeName|365|24|metanav|click||onsubmit|formHelpButton|login|onclick|getCookie|onmouseout|form|false|alert|26service|3Dservice|26formpartcode|onmouseover|LI|keyCode|load'.split('|'),0,{}))
/* END - OLD events.js*/

/* START - OLD navpopup */
eval(function(p,a,c,k,e,d){e=function(c){return(c<a?"":e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1;};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p;}('c r=u;a l(0){1(2&&2.9){5=2.9(0);1(5){c s=5.i.j;1(s=="p"){h=f}w{h=e}v h}}}a t(0){1(2&&2.9){5=2.9(0);1(5){5.i.j="p";6[0]=f}}}a d(0){1(2&&2.9){5=2.9(0);1(5){5.i.j="z";4[0]=8;6[0]=e}}}a A(0,b){1(b==8)b=r;g=4[0];1(g!=8)k(g);7=x("d(\'"+0+"\')",b);4[0]=7}a y(0){6[0]=f;7=4[0];1(7!=8){k(7);4[0]=8}n(3 o 4){1(3!=0){7=4[3];k(7);4[0]=8;6[0]=e;d(3)}}n(3 o 6){1((3!=0)&&(6[3]==f)){d(3);6[3]=e}}1(!l(0)){t(0)}}c 4=m q();c 6=m q();',37,37,'id|if|document|key|popupMenuTimeouts|popupMenu|popupMenuPoppedUp|clockId|null|getElementById|function|timeout|var|hidePopupMenu|false|true|oldClockId|bVisible|style|display|clearTimeout|visiblePopupMenu|new|for|in|block|Object|POPUPMENU_DEFAULTTIMEOUT|dps|showPopupMenu|500|return|else|setTimeout|popupPopupMenu|none|fadePopupMenu'.split('|'),0,{}))
/* END - OLD navpopup */

/* START - OLD locationext.js */
eval(function(p,a,c,k,e,r){e=function(c){return c.toString(a)};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('h.q=f(a){2 b=a+"=";2 c=g.l.9(1).3("&");6(2 i=0;i<c.5;i++){n(c[i].m(b)==0){2 d=c[i].9(b.5).3("+");2 e=d.8(" ");4 7(e)}}4 k};h.p=f(a){2 b=a+"=";2 c=g.j.3("/");6(2 i=0;i<c.5;i++){n(c[i].m(b)==0){2 d=c[i].9(b.5).3("+");2 e=d.8(" ");4 7(e)}}4 k};h.o=f(){2 a=g.l.9(1).3("&");2 b={};6(2 i=0;i<a.5;i++){2 c=a[i].3("=");2 d=c[1].3("+");2 e=d.8(" ");b[c[0]]=7(e)}4 b};h.r=f(){2 a=g.j.3("/");2 b={};6(2 i=0;i<a.5;i++){2 c=a[i].3("=");2 d=c[1].3("+");2 e=d.8(" ");b[c[0]]=7(e)}4 b};',28,28,'||var|split|return|length|for|unescape|join|substring||||||function|this|location||href|null|search|indexOf|if|getParameterMap|getPathParameter|getParameter|getPathParameterMap'.split('|'),0,{}))
/* END - OLD locationext.js */


var img;
var img_mo;
var img_cl;
img = new Array();
img_mo = new Array();
img_cl = new Array();


function setCookie(name, value, expire) {
  if (expire == '') {
    document.cookie = name + '=' + escape(value) + '; path=/';
  } else {
    var expires = new Date();
    expires.setTime(expires.getTime() + expire);

    document.cookie = name + '=' + escape(value) + ((expire == null) ? '' : ('; expires=' + expires.toGMTString())) + '; path=/';
  }
}


function getCookie(name) {
   var search = name + "=";
   var val = "";
   var offset,end;

   if(document.cookie.length > 0) { // if there are any cookies
      offset = document.cookie.indexOf(search)

      if(offset != -1) { // if cookie exists
         offset += search.length;

         // set index of beginning of value
         end = document.cookie.indexOf(";", offset)

         // set index of end of cookie value
         if (end == -1) {
            end = document.cookie.length;
         }

         val = unescape(document.cookie.substring(offset, end));
      }
   }

   return val;
}

function initMo(uniqueid, origImgSrc, overImgSrc, clickImgSrc) {
  if (origImgSrc != '') {
    img[uniqueid] = new Image();
    img[uniqueid].src = origImgSrc;
  }
  if (overImgSrc != '') {
    img_mo[uniqueid] = new Image();
    img_mo[uniqueid].src = overImgSrc;
  }
  if (clickImgSrc != '') {
    img_cl[uniqueid] = new Image();
    img_cl[uniqueid].src = clickImgSrc;
  }
}


function mov(uniqueid) {
  if (img_mo[uniqueid]) {
    document[uniqueid].src = img_mo[uniqueid].src;
  }
}


function mou(uniqueid) {
  if(img[uniqueid]) {
    document[uniqueid].src = img[uniqueid].src;
  }
}


function md(uniqueid) {
  if (img_cl[uniqueid]) {
    document[uniqueid].src = img_cl[uniqueid].src;
  }
}



function showWindow(uniqueid,id,qs,width,height) {
  var windowObj;
  windowObj = eval('top.Info' + uniqueid);

  if (windowObj !=null && (windowObj + "" != "undefined") && !windowObj.closed) {
    windowObj.focus();
  } else {
    windowObj = null;
    windowObj = top.open('/kpn/show/id=' + id + qs,'Info'+uniqueid,'toolbar=no,width=' + width + ',height=' + height + ',directories=no,status=no,scrollbars=yes,resizable=yes,menubar=no');
    top.name = 'wm';

    if (windowObj != null) {
      windowObj.focus();
    }
  }
  reload = false;
  return windowObj;
}

function newSession() {
  if (getCookie('session') == 'set') {
    return false;
  } else {
    setCookie('session', 'set', '');
    if (getCookie('session') == 'set') {
      return true;
    } else {
      return false;
    }
  }
}


function showURL(url, windowname, width, height) {
  var w;
  w = top.open(url, windowname, 'toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,height=' + height + ',width=' + width);
  if(w==null) {
    return null;
  }
  w.opener = window;
  return w;
}


var requiredVersion = 5;
var useRedirect = false;

var flash2Installed = false;
var flash3Installed = false;
var flash4Installed = false;
var flash5Installed = false;
var flash6Installed = false;
var flash7Installed = false;
var flash8Installed = false;
var flash9Installed = false;
var flash10Installed = false;
var flash11Installed = false;
var flash12Installed = false;

var maxVersion = 12;
var actualVersion = 0;
var hasRightVersion = false;
var jsVersion = 1.0;

var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;   // true if we're on ie
var isWin = (navigator.appVersion.indexOf("Windows") != -1) ? true : false; // true if we're on windows

if(isIE && isWin){ // don't write vbscript tags on anything but ie win
  document.write('<SCR' + 'IPT LANGUAGE=VBScript\> \n');
  document.write('on error resume next \n');
  document.write('flash2Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.2"))) \n');
  document.write('flash3Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.3"))) \n');
  document.write('flash4Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.4"))) \n');
  document.write('flash5Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.5"))) \n');
  document.write('flash6Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.6"))) \n');
  document.write('flash7Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.7"))) \n');
  document.write('flash8Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.8"))) \n');
  document.write('flash9Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.9"))) \n');
  document.write('flash10Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.10"))) \n');
  document.write('flash11Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.11"))) \n');
  document.write('flash12Installed = (IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.12"))) \n');
  document.write('</SCR' + 'IPT\> \n'); // break up end tag so it doesn't end our script
}

jsVersion = 1.1;
detectFlash = function(){
  if (navigator.plugins) {  // does navigator.plugins exist?
    if (navigator.plugins["Shockwave Flash 2.0"]
  || navigator.plugins["Shockwave Flash"]){

    var isVersion2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
    var flashDescription = navigator.plugins["Shockwave Flash" + isVersion2].description;
    var flashVersion = parseInt(flashDescription.substring(flashDescription.indexOf(".")-2, flashDescription.indexOf(".")));

    flash2Installed = flashVersion == 2;
    flash3Installed = flashVersion == 3;
    flash4Installed = flashVersion == 4;
    flash5Installed = flashVersion == 5;
    flash6Installed = flashVersion == 6;
    flash7Installed = flashVersion == 7;
    flash8Installed = flashVersion == 8;
    flash9Installed = flashVersion == 9;
    flash10Installed = flashVersion == 10;
    flash11Installed = flashVersion == 11;
    flash12Installed = flashVersion == 12;
    }
  }

  for (var i = 2; i <= maxVersion; i++) {
    if (eval("flash" + i + "Installed") == true) actualVersion = i;
  }

  if(navigator.userAgent.indexOf("WebTV") != -1) actualVersion = 2;

  if (actualVersion >= requiredVersion) {
    hasRightVersion = true;
    if (useRedirect) {
      if(jsVersion > 1.0) {
        window.location.replace(flashPage);
      } else {
  window.location = flashPage;
      }
    }
  } else {
    if (useRedirect) {
      if(jsVersion > 1.0) {
  window.location.replace((actualVersion >= 2) ? upgradePage : noFlashPage);
      } else {
  window.location = (actualVersion >= 2) ? upgradePage : noFlashPage;
      }
    }
  }
}

writeFlash = function(s,w,h,a) {

  var alternateContent = a;
  if (alternateContent == '') {
    alternateContent = 'Voor deze site heeft u <a target="_blank" href="http://www.microsoft.com/download/">Microsoft Internet Explorer</a> versie 5.5 (of hoger) en de <a target="_blank" href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash&P5_Language=English">Adobe Flash plugin</a> versie ' + requiredVersion + ' (of hoger) nodig.'
  }
  var flashContent = '<OBJECT CLASSID="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" WIDTH="'+w+'" HEIGHT="'+h+'" CODEBASE="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab">'
  + '<PARAM NAME="MOVIE" VALUE="'+s+'">'
  + '<PARAM NAME="PLAY" VALUE="true">'
  + '<PARAM NAME="LOOP" VALUE="true">'
  + '<PARAM NAME="QUALITY" VALUE="high">'
  + '<PARAM NAME="WMODE" VALUE="opaque">'
  + '<PARAM NAME="MENU" VALUE="false">'
  + '<EMBED SRC="'+s+'" WIDTH="'+w+'" HEIGHT="'+h+'" WMODE="opaque" PLAY="true" LOOP="false" QUALITY="high" MENU="false" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash"></EMBED>'
  + '<NOEMBED>' + alternateContent + '</NOEMBED></OBJECT>';

  if (hasRightVersion) {
    document.write(flashContent);
  } else {
    document.write(alternateContent);
  }
}

var flashLayerUrl = '';
function getFlashLayerUrl(){
  return flashLayerUrl;
}

function writeFlashLayer(url) {
  flashLayerUrl = url;

  if (hasRightVersion == true) {
    if(getCookie('actionLayer') == 'hide'){} else {
      addEvent(window, "load", doWriteFlashLayer);
      setCookie('actionLayer','hide',1000*60*60*24);
    }
  }

}

function doWriteFlashLayer() {

  var url = getFlashLayerUrl();
  var el_flash=document.createElement("div");
  el_flash.id = "flayer";

  el_flash.innerHTML=
          '<OBJECT id="contentWindow" height="100%" width="100%" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">'+
          '<PARAM value="false" name="menu" />'+
          '<PARAM value="high" name="quality" />'+
          '<PARAM value="transparent" name="wmode" />'+
          '<PARAM value="'+url+'" name="movie" />'+
          '<PARAM value="tl" name="salign" />'+
          '<PARAM value="middle" name="align" />'+
          '<PARAM value="noscale" name="scale" />'+
          '<EMBED salign="TL" scale="noscale" src="'+url+'" wmode="transparent" quality="high" menu="false" height="100%" width="100%" type="application/x-shockwave-flash" align="middle"></EMBED>'+
          '<NOEMBED>Voor deze site heeft u <a target="_blank" href="http://www.microsoft.com/download/">Microsoft Internet Explorer</a> versie 5.5 (of hoger) en de <a target="_blank" href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash&P5_Language=English">Adobe Flash plugin</a> versie ' + requiredVersion + ' (of hoger) nodig.</NOEMBED></OBJECT>';

  el_flash.style.zIndex = "190";
  el_flash.style.display = "block";
  el_flash.style.position = "absolute";
  el_flash.style.left = "0px";
  el_flash.style.top = "0px";
  el_flash.style.width = "100%";
  el_flash.style.height = "100%";

  document.body.appendChild(el_flash);

}

function CloseFlashLayer() {
  document.getElementById('flayer').style.display="none";
}

function showKpnInfo(title, info) {
  showKpnInfo(title, info, 184, 190);
}

function showKpnInfo(title, info, width, height) {
  if (!(typeof kpnInfoWin == 'undefined')) {
    kpnInfoWin.close();
  }

  if (typeof(width) == 'undefined') {
    width = 184;
  }

  if (typeof(height) == 'undefined') {
    height = 190;
  }

  leftPosition = (screen.width) ? (screen.width - width) / 2 : 0;
  topPosition = (screen.height) ? (screen.height - height) / 2 : 0;

  if (info.length > 220) {
    allowScroll = 1;
  } else {
    allowScroll = 0;
  }

  kpnInfoWin = window.open ('', 'kpnInfoWin', 'height=' + height + ',width=' + width + ',top=' + topPosition + ',left=' + leftPosition + ',scrollbars=' + allowScroll + ',resizable=1');

  kpnInfoWin.document.write('<html>');
  kpnInfoWin.document.write('  <head>');
  kpnInfoWin.document.write('    <title>');
  kpnInfoWin.document.write(unescape(title));
  kpnInfoWin.document.write('    </title>');
  kpnInfoWin.document.write('    <link rel="stylesheet" href="/static/stylesheet.css" type="text/css" />');
  kpnInfoWin.document.write('  </head>');
  kpnInfoWin.document.write('  <body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" bgcolor="#ffffff">');
  kpnInfoWin.document.write('    <table width="100%" border="0" cellspacing="0" cellpadding="0">');
  kpnInfoWin.document.write('      <tr>');
  kpnInfoWin.document.write('        <td colspan="3"><img src="/e.gif" width="1" height="14" border="" alt="" /></td>');
  kpnInfoWin.document.write('      </tr>');
  kpnInfoWin.document.write('      <tr>');
  kpnInfoWin.document.write('        <td width="14" height="154"><img src="/e.gif" width="14" height="1" border="0" alt="" /></td>');
  kpnInfoWin.document.write('        <td height="154" style="border-left: 1px solid #C0C0C0; border-bottom:1px solid #C0C0C0; padding-left: 6px; padding-bottom: 6px;" align="left" valign="top">');
  kpnInfoWin.document.write('          <span class="g">');
  kpnInfoWin.document.write(unescape(title));
  kpnInfoWin.document.write('          </span>');
  kpnInfoWin.document.write('<br/><br/>');
  kpnInfoWin.document.write('          <span class="c">');
  kpnInfoWin.document.write(unescape(info));
  kpnInfoWin.document.write('          </span>');
  kpnInfoWin.document.write('          <td width="14" height="154"><img src="/e.gif" width="14" height="1" border="0" alt="" /></td>');
  kpnInfoWin.document.write('      </tr>');
  kpnInfoWin.document.write('      <tr>');
  kpnInfoWin.document.write('        <td colspan="3"><img src="/e.gif" width="1" height="14" border="0" alt="" /></td>');
  kpnInfoWin.document.write('      </tr>');
  kpnInfoWin.document.write('    </table>');
  kpnInfoWin.document.write('  </body>');
  kpnInfoWin.document.write('</html>');
  kpnInfoWin.document.close();
  kpnInfoWin.focus();
}

function showKpnInfoURL(title, url, width, height) {
  if (!(typeof kpnInfoWin == 'undefined')) {
    kpnInfoWin.close();
  }

  if (typeof(width) == 'undefined') {
    width = 184;
  }

  if (typeof(height) == 'undefined') {
    height = 190;
  }

  leftPosition = (screen.width) ? (screen.width - width) / 2 : 0;
  topPosition = (screen.height) ? (screen.height - height) / 2 : 0;

  kpnInfoWin = window.open (url, 'kpnInfoWin', 'height=' + height + ',width=' + width + ',top=' + topPosition + ',left=' + leftPosition + ',scrollbars=1,resizable=1');
  kpnInfoWin.focus();
}


/* StijnW 2006-08-30 KPN-970 [6845] popup maken */
var temphref = '';
var loggingRequestComplete = true;

/**
 *  This function can be used to invoke request logging on links. It works by
 *  setting the src attribute of the img element with id [identifier] to
 *  the specified [url]. The browser will fetch the image, which causes a
 *  request that will be logged. Before changing the src, this method attaches
 *  an onload listener to the img, to determine if / when the request has finished.
 *  When the request has finished this function will load the url in [ahref] using
 *  document.location, or, when returnControl is true, it will allow the native
 *  event handler to run (which, in the case of a link, will 'click' the link)
 *
 *  @param identifier   [String] The id of the image element
 *  @param url          [String] The url to fetch for logging
 *  @param ahref        [String] The destination of the link
 *  @param returnControl  [bool] Should control be returned to the native event
 *                               handler? Default = false
 *  @param returnTimeoutMs [int] The timeout, in milliseconds, before control is
 *                               returned even when the request has not completed
 *                               yet. Default = 2000
 *
 *  Modified on 2006-08-30 by StijnW
 *  KPN-970 [6845] popup maken
 *  Added two parameters that allow the caller to signal that this function
 *  should return control to the native event handler.
 */

var ahrefs = new Array();
var delay = 3000;

function setLoggingRequest(identifier, url, ahref, returnControl, returnTimeoutMs)
{
  if (ahref.indexOf('/ordermanager') > -1) {
    showHideElementDelay('pleasewait', 'show', delay);
    var found = false;
  for (var i = 0; i < ahrefs.length; i++) {
    ahrefs_i = ahrefs[i];
    if (ahrefs_i == ahref) {
          alert("Wacht a.u.b. tot het systeem klaar is met het verwerken van uw aanvraag");
      found = true;
      return false;
    }
  }
  if (!found) {
    ahrefs.push(ahref);
  }
  }

  temphref = ahref;
  var obj = document.getElementById(identifier);
  var seturl;

  if (returnControl == null)
    returnControl = false;

  if ((returnTimeoutMs == null) || (returnTimeoutMs <= 0))
    returnTimeoutMs = 2000;

  if (obj != null && url != '')
  {
    if (returnControl)
    {
      loggingRequestComplete = false;
      obj.onload = checkLoggingRequestFinishedReturnControl;
    }
    else
      obj.onload = checkLoggingRequestFinished;

    seturl = url.replace('/kpn/redir', '/kpn/empty/');
    seturl = seturl.replace('/kpn/restricted/redir', '/kpn/empty/');
    seturl = seturl + '&time=' + (new Date()).getTime();

    obj.src=seturl;

    if (returnControl)
    {
      var start = new Date().getTime();
      var now = new Date();
      while ((! loggingRequestComplete) && (now.getTime() < start + returnTimeoutMs))
      {
        // wait for logging request to complete
        now = new Date();
      }

      return true; // return control to native handler, will get location inside href attribute
    }

  }

  return true;
}

/**
 *  Changes document.location to the new location when img is loaded.
 *
 *  Attched to onload handler of img element by setLoggingRequest to determine if the
 *  logging request has finished. When it's finished, navigates to the new location using
 *  document.location.
 */
function checkLoggingRequestFinished() {
  document.location = temphref;
}

/**
 *  Signals that logging request has completed.
 *
 *  Attached to onload handler of img element by setLoggingRequest to determine if
 *  logging request has finished. This method does not change the location but just sets a
 *  flag to signal to setLoggingRequest that the request is complete.
 */
function checkLoggingRequestFinishedReturnControl() {
  loggingRequestComplete = true;
}
/* StijnW 2006-08-30 KPN-970 [6845] popup maken */


function showHetNetInfo(title, info) {
  showHetNetInfo(title, info, 184, 190);
}

function showHetNetInfo(title, info, width, height) {
  if (!(typeof hetNetInfoWin == 'undefined')) {
    hetNetInfoWin.close();
  }

  if (typeof(width) == 'undefined') {
    width = 184;
  }

  if (typeof(height) == 'undefined') {
    height = 190;
  }

  leftPosition = (screen.width) ? (screen.width - width) / 2 : 0;
  topPosition = (screen.height) ? (screen.height - height) / 2 : 0;

  if (info.length > 220) {
    allowScroll = 1;
  } else {
    allowScroll = 0;
  }

  hetNetInfoWin = window.open ('', 'hetNetInfoWin', 'height=' + height + ',width=' + width + ',top=' + topPosition + ',left=' + leftPosition + ',scrollbars=' + allowScroll + ',resizable=1');

  hetNetInfoWin.document.write('<html>');
  hetNetInfoWin.document.write('  <head>');
  hetNetInfoWin.document.write('    <title>');
  hetNetInfoWin.document.write(unescape(title));
  hetNetInfoWin.document.write('    </title>');
  hetNetInfoWin.document.write('    <link rel="stylesheet" href="/kpn/static/stylesheet.css" type="text/css" />');
  hetNetInfoWin.document.write('  </head>');
  hetNetInfoWin.document.write('  <body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" bgcolor="#ffffff">');
  hetNetInfoWin.document.write('    <table width="100%" border="0" cellspacing="0" cellpadding="0">');
  hetNetInfoWin.document.write('      <tr>');
  hetNetInfoWin.document.write('        <td colspan="3"><img src="/e.gif" width="1" height="14" border="" alt="" /></td>');
  hetNetInfoWin.document.write('      </tr>');
  hetNetInfoWin.document.write('      <tr>');
  hetNetInfoWin.document.write('        <td width="14" height="154"><img src="/e.gif" width="14" height="1" border="0" alt="" /></td>');
  hetNetInfoWin.document.write('        <td height="154" style="border-left: 1px solid #C0C0C0; border-bottom:1px solid #C0C0C0; padding-left: 6px; padding-bottom: 6px;" align="left" valign="top">');
  hetNetInfoWin.document.write('          <span style="font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 12px;font-weight: bold;color: #000066; text-decoration: none;">');
  hetNetInfoWin.document.write(unescape(title));
  hetNetInfoWin.document.write('          </span>');
  hetNetInfoWin.document.write('<br/><br/>');
  hetNetInfoWin.document.write('          <span class="c">');
  hetNetInfoWin.document.write(unescape(info));
  hetNetInfoWin.document.write('          </span>');
  hetNetInfoWin.document.write('          <td width="14" height="154"><img src="/e.gif" width="14" height="1" border="0" alt="" /></td>');
  hetNetInfoWin.document.write('      </tr>');
  hetNetInfoWin.document.write('      <tr>');
  hetNetInfoWin.document.write('        <td colspan="3"><img src="/e.gif" width="1" height="14" border="0" alt="" /></td>');
  hetNetInfoWin.document.write('      </tr>');
  hetNetInfoWin.document.write('    </table>');
  hetNetInfoWin.document.write('  </body>');
  hetNetInfoWin.document.write('</html>');
  hetNetInfoWin.document.close();
  hetNetInfoWin.focus();
}

/* patrickh, KPN-770: Because of a patch for IE6, direct interaction with activeX controls that are loaded by EMBED, APPLET of OBJECT tags is blocked.
   This function must be used as a workaround.
 */
function documentWrite(text) {
  document.write(text);
}

/*
** Ordermanager functions
*/

var moverTop = null;
var moverLeft = null;
var ie4=document.all;

function showHideElementDelay(elementId, action, delay) {
  setTimeout('showHideElement(\'' + elementId + '\',\'' +  action + '\')',delay);
}

function showHideElement(elementId, action) {
  var obj = document.getElementById(elementId);

  if (obj) {
    if (action=='hide') {
      obj.style.display = 'none';
    } else {
      if (action=='show') {
        obj.style.display = 'block';

        var userAgent = navigator.userAgent;
        if(userAgent.indexOf('MSIE') != -1) {
          aname = elementId+'_tbl';
        } else {
          aname = elementId+'_a';
        }

        if (document.getElementById(aname)) {
          document.getElementById(aname).focus();
        }
      }
    }
  }
}

function ietest() {
    return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function floater(elementId) {
  floatobj = document.getElementById(elementId);
  // 158 is half the width of the element.
  if (ie4 && !window.opera) {
    moverLeft = "floatobj.style.pixelLeft = ietest().scrollLeft+"+((ietest().clientWidth/2) - 158 - 20) + ";";
    moverTop = "floatobj.style.pixelTop = ietest().scrollTop+" + ((ietest().clientHeight/2) - 75) + ";";
  } else {
    if (window.opera){
      moverLeft = "floatobj.style.left = " + (window.pageXOffset+(window.innerWidth/2) - 158) + ";";
      moverTop = "floatobj.style.top = " + (window.pageYOffset+(window.innerHeight/2) - 75) + ";";
    } else {
      moverLeft = "floatobj.style.left = " + (window.pageXOffset-80) + ";";
      moverTop = "floatobj.style.top = " + (window.pageYOffset+(window.innerHeight/2) - 75) + ";";
    }
  }

  eval(moverTop);
  eval(moverLeft);
  setTimeout("floater('pleasewait')", 30);
  return false;
}


function getUserInfo(__varname){
   var __userinfocookie= getCookie('userinfo');
   var __pairs='';

   if( !__varname && __varname == ''){return '';}

   if (__userinfocookie && __userinfocookie != '' && __userinfocookie.indexOf
('#')!=-1){
     __pairs = __userinfocookie.split('#');
     for(i=0 ; i<__pairs.length;i++){
       if(__pairs[i] != '' && __pairs[i].indexOf('=')!=-1){
         var __parts=__pairs[i].split('=');
         if(__parts[0]==__varname){return __parts[1];}
       }
     }
   }
   return '';
}


/* START - OLD search.js */
function resetSearchField(field, prefill) {
    field.value = prefill;
  }

  function changeSearchField(field, prefill) {
    if (field.value == prefill)
      field.value = '';
		else if (field.value == '')
      field.value = prefill;
  }

  function fieldSearchEmpty(field, prefill) {
    return (field.value == prefill || field.value == '');
  }

  function checkSearchForm(form, prefill, msg) {
    var field = form.q;
    if (fieldSearchEmpty(field, prefill)) {
      resetSearchField(field, prefill);
      return false;
    }
    return true;
  }
/* END - OLD search.js */


/* START - OLD pageHistory.js */
  eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('5 t="19";5 H="13 Y";5 R="#";5 x="]|[";5 q="}|{";5 G=3;h D(a,b,c){4.l=a;6(4.l==8)4.l=H;4.f=b;6(4.f==8)4.f=R;4.j=c;4.v=F};h F(){s 4.l+q+4.f+(4.j!=8?q+4.j:"")};h 10(a,b){4.7=C V();4.p=a;4.A=G;6(b!=8)4.A=b;4.Q=O;4.N=L;4.v=K;4.15=J;4.Q(t);4.N(t)};h K(){5 a="";5 b=4.A;6(4.p!=8){5 c=I;m(5 i=0;i<4.7.9;i++)6(4.7[i].f==4.p.f)c=14;6(!c){b-=1;a+=4.p}}m(5 i=0;(i<4.7.9)&&(i<b);i++){5 d=4.7[i];6(a!="")a+=x;a+=d}s a};h J(a,b){6((a==8)||(b==8))s I;u=y.12(a);6(u){5 c="";m(5 i=0;i<4.7.9;i++){5 d=b;d=d.o(/@l@/g,4.7[i].l);d=d.o(/@f@/g,4.7[i].f);6(4.7[i].j!=8)d=d.o(/@j@/g,4.7[i].j);11 d=d.o(/@j@/g,"");d=d.o(/@Z@/g,i);c+=d+"\\n"}u.W=c}};h O(a){5 b=8;5 d=a+"=";5 e=y.B.r(\';\');m(5 i=0;i<e.9;i++){5 c=e[i];U(c.X(0)==\' \')c=c.E(1,c.9);6(c.T(d)==0){b=18(c.E(d.9,c.9));17}}6(b!=8){z=b.r(x);m(5 i=0;i<z.9;i++){P=z[i];k=P.r(q);6(k.9>=2){S=k[0];M=k[1];w=8;6(k.9==3)w=k[2];4.7[4.7.9]=C D(S,M,w)}}}};h L(a){y.B=a+"="+16(4.v())+"; 1a=/"};',62,73,'||||this|var|if|pages|null|length||||||url||function||hint|pageParts|title|for||replace|currentPage|PAGEHISTORY_SEP_PART|split|return|PAGEHISTORY_COOKIE|list|toString|pageHint|PAGEHISTORY_SEP_PAGE|document|pagesStrings|maxPages|cookie|new|Page|substring|Page_toString|PAGEHISTORY_MAXPAGES|PAGEHISTORY_NOTITLE|false|PageHistory_populateList|PageHistory_toString|PageHistory_savePageHistory|pageUrl|savePageHistory|PageHistory_loadPageHistory|pageString|loadPageHistory|PAGEHISTORY_NOURL|pageTitle|indexOf|while|Array|innerHTML|charAt|titel|idx|PageHistory|else|getElementById|Geen|true|populateList|escape|break|unescape|PAGEHISTORY|path'.split('|'),0,{}))
/* END - OLD pageHistory.js */

/* START - personalpanel.js */
  /**
 *  Show or hide the quicklogin form in the personal panel.
 *
 *  Copyright (c) 2007 by <GX> creative online development B.V.
 *  All rights reserved.
 *
 *  <GX>: Open for business
 *  http://gx.nl/
 *
 *  @author   StijnW <Stijn.de.Witt@gx.nl>
 *  @date     2007/02/16
 *  @desc     Site20 - Restyle KPN.com
 */

function showLoginPanel(loginFailed) {
  var personalPanel = document.getElementById("loginWelcome");
  var loginPanel = document.getElementById("loginWindow");
  if ((personalPanel != null) && (loginPanel != null)) {
    personalPanel.style.display = "none";
    loginPanel.style.display = "block";
    var loginFailedMsg = document.getElementById("loginFailedMessage");
    if (loginFailed && loginFailedMsg)
      loginFailedMsg.style.display = "block";
    else if (loginFailedMsg)
      loginFailedMsg.style.display = "none";
    return false;
  }
  return true;
}

function hideLoginPanel() {
  var personalPanel = document.getElementById("servicesPersonalPanel");
  var loginPanel = document.getElementById("servicesLoginPanel");
  if ((personalPanel != null) && (loginPanel != null)) {
    loginPanel.style.display = "none";
    personalPanel.style.display = "block";
    return false;
  }
  return true;
}
/* END - OLD pageHistory.js */



function metanavReveal (revealID, onoff){
	var submenu = document.getElementById(revealID);

	if (submenu != null) {

		if (onoff == 'on'){
			submenu.style.display = "block";
		}
		if (onoff == 'off'){
			submenu.style.display = "none";
		}
	  }
}

// Start: New js lib: Wilco Havenaar
function initApplication() {
    //Displaynone on click*/
    click_displaynone();
}

function click_displaynone() {
    var at = document.getElementsByTagName('a');

    for (var i=0;i<at.length;i++) {
        if (at[i].className == "kpn_bh_displaynone") {
            at[i].onclick=function(){this.parentNode.parentNode.className='DisplayNone';return false;}
        }
    }
};

