 
 var lookup = new Array();
 var txt_total ="";
 var txt_error = "Er zijn problemen ontstaan bij het verzenden van de gegevens.\nHet volgende gegeven is niet of onjuist ingevuld:\n\n";
 var version=0
 var ie5 = false;

 if (navigator.appVersion.indexOf("MSIE")!=-1){
  temp    = navigator.appVersion.split("MSIE")
  version = parseFloat(temp[1]);
  if(version<=5.5) ie5 = true;
 }

 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function open_popup(url)
 {
  newwin=window.open(url,"","resizable=yes,scrollbars=1,width=780,height=550");
  if(parseInt(navigator.appVersion)>3){
   setTimeout('newwin.focus();',250);
 }}

 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function footer()
 {
  txt  = "<div class=\"payoff\">Enkhuizer Almanak - 415de jaargang voor het jaar 2010.";
  txt += "<br />Standaard editie 4,95. ";
  txt += "Standaard editie 4,95. Luxe/schippers editie 6,50. Enkhuizer Kinder Almanak, derde jaargang ";
  txt += "4,95.</div>";


  document.writeln(txt);
 }


 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function validate_required(field,alerttxt)
 {var txt;

  with (field)
  {
   if(value==null||value=="")
   {
    alert(txt_error+alerttxt);
    return false;
   }
   else {
    return true;
 }}}


 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function validate_email(field,alerttxt)
 {var apos,dotpos;

  with(field)
  {
   apos   = value.indexOf("@")
   dotpos = value.lastIndexOf(".")

   if(apos<1 || dotpos-apos<2) 
   {
    alert(txt_error+alerttxt);return false
   }
   else {
    return true;
   }
  }
 }


 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function valButton(btn,alerttxt)
 {var i,cnt = -1;

  for(i=btn.length-1; i>-1; i--) {
   if(btn[i].checked){
    cnt = i;
    i   = -1;
  }}

  if(cnt>-1){ return true;}
  else      { alert(txt_error+alerttxt); return false;}
 }


 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/
 
 function show_header(location,page)
 {


  txt  = "<div id=\"almanak\">\n";
  txt += " <div id=\"pageflip\"><strong>You need to upgrade your Flash Player</strong></div>\n";
  txt += " <script type=\"text/javascript\">\n";
  txt += " // <![CDATA[\n";
  txt += " var so = new SWFObject(\"";
  txt += location=="homepage" ? "general" : "../general";
  txt += "/pageflip.swf\", \"pageflip\", \"200\", \"150\", \"6\", \"#FFFFFF\");\n";
  txt += " so.addParam(\"wmode\", \"transparent\");\n";
  txt += " so.addVariable(\"chapter\", \""+location+"\");\n";
  txt += " so.addVariable(\"page\", \""+page+"\");\n";
  txt += " so.write(\"pageflip\");\n";
  txt += " // ]]>\n";
  txt += " </script>\n";
  txt += "</div> \n";

  // alert("page: "+page);

  document.writeln(txt);


 }


 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/
 
 function show_footer(location)
 {var txt,s;

  s  = " style=\"";
  s += ie5 || version==6 ? "display: inline;" : "display: block;";
  s += "\"";

  txt  = "<div id=\"footer\">\n";
  txt += "<div id=\"link\""+s+"><a href=\""+(location=="homepage" ? "" : "../")+"general/contact.html\" onfocus=\"this.blur()\""+s+">contact</a></div>\n";
  txt += "<div id=\"link\""+s+"><a href=\""+(location=="homepage" ? "" : "../")+"general/seizoenbrief.html\" onfocus=\"this.blur()\""+s+">seizoenbrief</a></div>\n";
  txt += "<div id=\"link\""+s+">de Enkhuizer Almanak 415de jaargang voor het jaar 2010&nbsp;&nbsp;</div>\n";
  txt += "<div class=\"clear\"></div>\n";
  txt += "<div class=\"hr\"><hr /></div>\n";
  txt += "</div>\n";

  document.writeln(txt);
 }


 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/
 
 function show_dynamicdata(location,page)
 {
  var path  = location=="homepage" ? "" : "../"
  var id    = "";
  var txt   = "";
  txt_total = "";


 /**********************************************************************************/
 /* enkhuizer almanak                                                              */
 /**********************************************************************************/

  document.writeln("<div id=\"header\">");

  show_header(location,page);
  show_footer(location);

  document.writeln("</div>");

  /**********************************************************************************/
  /* enkhuizer almanak                                                              */
  /**********************************************************************************/


  txt       = "<div id=\"navigation\">\n";
  txt      += "<ul class=\"mainNav\">\n";


  // alert(txt);

  txt_total+=txt;

  document.writeln(txt);


  /**********************************************************************************/
  /* historie                                                                       */
  /**********************************************************************************/

  write_menu(location=="laatste nieuws" ? 1 : 0, "laatste nieuws", path+"laatste_nieuws/index.html");

  if(location=="laatste nieuws"){
   add_lookup("laatste nieuws"       , path+"laatste_nieuws/index.html");
   add_lookup("Jan Smit en opa Hein" , path+"laatste_nieuws/jan_smit_en_opa_hein.html");
   add_lookup("telegraaf alle tijden", path+"laatste_nieuws/telegraaf_alle_tijden.html");
   add_lookup("wanneer jas aan?"     , path+"laatste_nieuws/noordhollands_dagblad_jas.html");



   write_submenu(page);
  }


  /**********************************************************************************/
  /* historie                                                                       */
  /**********************************************************************************/

  write_menu(location=="historie" ? 1 : 0, "historie", path+"historie/index.html");

  if(location=="historie"){
   add_lookup("historisch overzicht", path+"historie/index.html");
   add_lookup("boekdruk kunst", path+"historie/boekdruk_kunst.html");
   add_lookup("opzet almanak", path+"historie/opzet_almanak.html");
   add_lookup("geschiedenis", path+"historie/geschiedenis.html");
   add_lookup("familie Stichter", path+"historie/familie_stichter.html");
   add_lookup("oorsprong almanak", path+"historie/oorsprong_almanak.html");
   add_lookup("ontstaan ea museum", path+"historie/ontstaan_almanak_museum.html");
   add_lookup("ea museum", path+"historie/ea_museum.html");
   write_submenu(page);
  }

  /**********************************************************************************/
  /* varia                                                                      */
  /**********************************************************************************/

  write_menu(location=="varia" ? 1 : 0, "varia", path+"varia/index.html");

  if(location=="varia"){
   add_lookup("gebruik vlaggen", path+"varia/index.html");
   add_lookup("verduisteringen", path+"varia/zons_en_maansverduistering.html");
   add_lookup("lengen en korten dagen", path+"varia/lengen_en_korten_dagen.html");
   write_submenu(page);
  }

  /**********************************************************************************/
  /* almanak spel                                                                   */
  /**********************************************************************************/

  write_menu(location=="spel" ? 1 : 0, "almanak spel", path+"spel/index.html");

  /**********************************************************************************/
  /* kalender                                                                    */
  /**********************************************************************************/

  write_menu(location=="kalender" ? 1 : 0, "kalender", path+"kalender/index.html");

  if(location=="kalender"){
   add_lookup("eeuwig durende kalander", path+"kalender/index.html");
   add_lookup("de dierenriem", path+"kalender/dierenriem.html");
   add_lookup("herkomst maandnamen", path+"kalender/herkomst_maandnamen.html");
   write_submenu(page);
  }

  /**********************************************************************************/
  /* weer                                                                    */
  /**********************************************************************************/

  write_menu(location=="weer" ? 1 : 0, "weer", path+"weer/index.html");

  /**********************************************************************************/
  /* getijden                                                                */
  /**********************************************************************************/

  write_menu(location=="getijden" ? 1 : 0, "getijden", path+"getijden/index.html");

  /**********************************************************************************/
  /* feestdagen                                                                      */
  /**********************************************************************************/

  write_menu(location=="feestdagen" ? 1 : 0, "feestdagen", path+"php/index.php?page=feestdagen");


  /**********************************************************************************/
  /* vraagenaanbod                                                              */
  /**********************************************************************************/

  write_menu(location=="vraag en aanbod" ? 1 : 0, "vraag en aanbod", path+"php/index.php?page=vraag");

  if(location=="vraag en aanbod"){
   add_lookup("vraag", path+"php/index.php?page=vraag");
   add_lookup("aanbod", path+"php/index.php?page=aanbod");
   write_submenu(page);
  }

  /**********************************************************************************/
  /* winkeltje                                                                 */
  /**********************************************************************************/

  write_menu(location=="winkeltje" ? 1 : 0, "winkeltje", path+"winkeltje/index.php");

  if(location=="winkeltje"){
   add_lookup("overzicht"                 , path+"winkeltje/index.php");
   add_lookup("almanak"                   , path+"winkeltje/details.php?product_id=1"); 
   add_lookup("almanak luxe editie"       , path+"winkeltje/details.php?product_id=2");
   add_lookup("almanak kinder editie"     , path+"winkeltje/details.php?product_id=4");
   add_lookup("standaard abonnementen"    , path+"winkeltje/details.php?product_id=5");
   add_lookup("luxe abonnementen"         , path+"winkeltje/details.php?product_id=6");
   add_lookup("cd dronkemansmoed"         , path+"winkeltje/details.php?product_id=7");
   add_lookup("cd hollantsche schou..."   , path+"winkeltje/details.php?product_id=8");
   add_lookup("cd over zee en zuks"       , path+"winkeltje/details.php?product_id=9");
   add_lookup("verjaardagskaarten"        , path+"winkeltje/details.php?product_id=11");
   add_lookup("verjaardagskalender"       , path+"winkeltje/details.php?product_id=12");
   add_lookup("schaatsmuts"               , path+"winkeltje/details.php?product_id=10");
   write_submenu("-"+page);
  }

  /**********************************************************************************/
  /* schaatsploeg                                                                 */
  /**********************************************************************************/

  write_menu(location=="schaatsploeg" ? 1 : 0, "schaatsploeg", "javascript:open_popup('"+path+"schaatsploeg/index.html"+"')\;");

  /**********************************************************************************/
  /* wijsheden                                                                     */
  /**********************************************************************************/	
	
  write_menu(location=="wijsheden" ? 1 : 0, "wijsheden", path+"php/index.php?page=wijsheden");

  /**********************************************************************************/
  /* dagjeuit                                                                       */
  /**********************************************************************************/
	
  write_menu(location=="dagjeuit" ? 1 : 0, "dagjeuit", path+"dagjeuit/index.html");

  if(location=="dagjeuit"){
   add_lookup("arrangementen"          , path+"dagjeuit/index.html");
   add_lookup("culinaire wandeling"    , path+"dagjeuit/culinaire_wandeling.html");
   add_lookup("enkhuizen - all In"     , path+"dagjeuit/arrangement_allin.html");
   add_lookup("stadswandeling plus!"   , path+"dagjeuit/arrangement_stadswandeling_plus.html");
   write_submenu(page);
  }

  /**********************************************************************************/
  /* weer                                                                    */
  /**********************************************************************************/

  write_menu(location=="kinderen" ? 1 : 0, "...voor de kinderen", path+"kinderen/index.html");

  if(location=="kinderen"){
   add_lookup("Krassie in Enkhuizen", path+"kinderen/index.html");
   add_lookup("lesbrief"            , path+"kinderen/lesbrief.html");
   write_submenu(page);
  }






  txt = " </ul>\n";
  txt = "</div>\n";

  document.writeln(txt);
 
  txt_total+=txt;

  // alert(txt_total);



 }

 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function add_lookup(txt,url)
 {
  var i        = lookup.length;
  lookup[i]    = new Array();
  lookup[i][0] = txt;
  lookup[i][1] = url;
 }

 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function write_submenu(page)
 {var txt,t,a;

  txt  = " </ul>";
  txt += " <ul class=\"subNav\">\n";

  s  = " class=\"subNav_selection\" style=\"";
  s += ie5 ? "display: inline;" : "display: block;";
  s += "\"";

  for(a=0; a<lookup.length; a++){
   txt += "  <li" + (lookup[a][0]==page ? s+">" : ">") + (lookup[a][0]==page ? "<em class=\"subNav_selection\">" :  "<a href=\"" + lookup[a][1] +"\" onfocus=\"this.blur()\" target=\"_top\">") + "&nbsp;&nbsp;&nbsp;"+lookup[a][0] + (lookup[a][0]==page ? "</em>" : "</a>") + "</li>\n";
  }

  txt += " </ul>\n";
  txt += " <ul class=\"mainNav\">\n";

  document.writeln(txt);
 txt_total+=txt;

//  alert(txt);

 }

 function checkForm(f)
 {
	 
	 var errorMsg 	= "";
	 
	 if (f.geslacht.value == '')
	 {
		 errorMsg = "U bent vergeten een Titel in te vullen.";
	 }
	 
	 if (f.voorletters.value == '')
	 {
		 errorMsg = "U bent vergeten voorletters in te vullen.";
	 }
	 
	 if (f.naam.value == '')
	 {
		 errorMsg = "U bent vergeten een achternaam in te vullen.";
	 }
	 
	 if (f.straat.value == '')
	 {
		 errorMsg = "U bent vergeten een straat in te vullen.";
	 }
	 
	 if (f.huisnummer.value == '')
	 {
		 errorMsg = "U bent vergeten een huisnummer in te vullen.";
	 }
	 
	 if (f.postcode.value == '')
	 {
		 errorMsg = "U bent vergeten een postcode in te vullen.";
	 }
	 
	 if (f.woonplaats.value == '')
	 {
		 errorMsg = "U bent vergeten een woonplaats in te vullen.";
	 }
	 
	 if (f.land.value == '')
	 {
		 errorMsg = "U bent vergeten een land in te vullen.";
	 }
	 
	 if (f.telefoon.value == '')
	 {
		 errorMsg = "U bent vergeten een telefoonnummer in te vullen.";
	 }
	 
	 if (f.email.value == '' || f.email.value.search(/^.*@.*\..*$/) == -1)
	 {
		 errorMsg = "U bent vergeten een (goed) e-mail adres in te vullen in te vullen.";
	 }
	 
	 if (f.betaalwijze.value == '')
	 {
		 errorMsg = "U bent vergeten een betaalwijze op te geven.";
	 }
	 
	 if (errorMsg)
	 {
		 alert(errorMsg);
		 return false;
	 }
	 
	 return true;
 }

 /***********************************************************************************/
 /* enkhuizer almanak                                                               */
 /***********************************************************************************/

 function write_menu(index,name,location)
 {var txt,s;
  
  s  = " class=\"mainNavSelected\" style=\"";
  s += ie5 ? "display: inline; " : "display: block; ";
  s += "\"";

  txt  = " <li"+ (index==1 ? s+">" : ">");
  txt += (index==1 ? "<em class=\"mainNavSelected\">" : "<a href=\"" + location +"\" onfocus=\"this.blur()\" " + (name=="schaatsploeg" ? "" : "target=\"_top\"") + ">");
  txt += "&nbsp;&nbsp;&nbsp;"+ name;
  txt += (index==1 ? "</em>" : "</a>") + "</li>\n";

  txt_total+=txt;

  document.writeln(txt);

  // alert(txt);
 }


 /*******************************************************************************************/
 /*                                                                                         */
 /* SWFObject v1.5: Flash Player detection and embed - http://blog.deconcept.com/swfobject/ */
 /*                                                                                         */
 /* SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License:              */
 /* http://www.opensource.org/licenses/mit-license.php                                      */
 /*                                                                                         */
 /*******************************************************************************************/

 if(typeof deconcept=="undefined"){var deconcept=new Object();}if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a){if(!document.getElementById){return;}this.DETECT_KEY=_a?_a:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1);}if(id){this.setAttribute("id",id);}if(w){this.setAttribute("width",w);}if(h){this.setAttribute("height",h);}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(c){this.addParam("bgcolor",c);}var q=_7?_7:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var _c=(_8)?_8:window.location;this.setAttribute("xiRedirectUrl",_c);this.setAttribute("redirectUrl","");if(_9){this.setAttribute("redirectUrl",_9);}};deconcept.SWFObject.prototype={useExpressInstall:function(_d){this.xiSWFPath=!_d?"expressinstall.swf":_d;this.setAttribute("useExpressInstall",true);},setAttribute:function(_e,_f){this.attributes[_e]=_f;},getAttribute:function(_10){return this.attributes[_10];},addParam:function(_11,_12){this.params[_11]=_12;},getParams:function(){return this.params;},addVariable:function(_13,_14){this.variables[_13]=_14;},getVariable:function(_15){return this.variables[_15];},getVariables:function(){return this.variables;},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){_16[_16.length]=key+"="+_18[key];}return _16;},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}_19="<embed type=\"application/x-shockwave-flash\" src=\""+this.getAttribute("swf")+"\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\"";_19+=" id=\""+this.getAttribute("id")+"\" name=\""+this.getAttribute("id")+"\" ";var _1a=this.getParams();for(var key in _1a){_19+=[key]+"=\""+_1a[key]+"\" ";}var _1c=this.getVariablePairs().join("&");if(_1c.length>0){_19+="flashvars=\""+_1c+"\"";}_19+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}_19="<object id=\""+this.getAttribute("id")+"\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\">";_19+="<param name=\"movie\" value=\""+this.getAttribute("swf")+"\" />";var _1d=this.getParams();for(var key in _1d){_19+="<param name=\""+key+"\" value=\""+_1d[key]+"\" />";}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+="<param name=\"flashvars\" value=\""+_1f+"\" />";}_19+="</object>";}return _19;},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var _23=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_23=new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var axo=1;var _26=3;while(axo){try{_26++;axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_26);_23=new deconcept.PlayerVersion([_26,0,0]);}catch(e){axo=null;}}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(e){try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");_23=new deconcept.PlayerVersion([6,0,21]);axo.AllowScriptAccess="always";}catch(e){if(_23.major==6){return _23;}}try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(e){}}if(axo!=null){_23=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}}}return _23;};deconcept.PlayerVersion=function(_29){this.major=_29[0]!=null?parseInt(_29[0]):0;this.minor=_29[1]!=null?parseInt(_29[1]):0;this.rev=_29[2]!=null?parseInt(_29[2]):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.major<fv.major){return false;}if(this.major>fv.major){return true;}if(this.minor<fv.minor){return false;}if(this.minor>fv.minor){return true;}if(this.rev<fv.rev){return false;}return true;};deconcept.util={getRequestParameter:function(_2b){var q=document.location.search||document.location.hash;if(_2b==null){return q;}if(q){var _2d=q.substring(1).split("&");for(var i=0;i<_2d.length;i++){if(_2d[i].substring(0,_2d[i].indexOf("="))==_2b){return _2d[i].substring((_2d[i].indexOf("=")+1));}}}return "";}};deconcept.SWFObjectUtil.cleanupSWFs=function(){var _2f=document.getElementsByTagName("OBJECT");for(var i=_2f.length-1;i>=0;i--){_2f[i].style.display="none";for(var x in _2f[i]){if(typeof _2f[i][x]=="function"){_2f[i][x]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(id){return document.all[id];};}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject;



