sfHover = function() {
  	if (!window.attachEvent) {return false;}
        var sfEls = document.getElementById("nav").getElementsByTagName("LI");
        for (var i=0; i<sfEls.length; i++) {
                sfEls[i].onmouseover=function() {
                        this.className+=" sfhover";
                }
                sfEls[i].onmouseout=function() {
                        this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
                }
        }
}

//if (window.attachEvent) window.attachEvent("onload", sfHover);

function MM_validateFormNL() { //v4.0
  var i,p,q,nm,test,num,min,max,errors='',args=MM_validateFormNL.arguments;

  for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args[i]);
    if (val) { nm=val.name; if ((val=val.value)!="") {
      if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
        if (p<1 || p==(val.length-1)) errors+='- '+URLDecode(nm)+' moet een geldig e-mail adres bevatten.\n';
      } else if (test!='R') { num = parseFloat(val);
        if (isNaN(val)) errors+='- '+URLDecode(nm)+' must contain a number.\n';
        if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
          min=test.substring(8,p); max=test.substring(p+1);
          if (num<min || max<num) errors+='- '+URLDecode(nm)+' must contain a number between '+min+' and '+max+'.\n';
    } } } else if (test.charAt(0) == 'R') errors += '- '+URLDecode(nm)+' ontbreekt\n'; }
  } if (errors) alert('De volgende informatie is incorrect:\n'+errors);

  document.MM_returnValue = (errors == '');
}

function URLDecode(psEncodeString)
{
  // Create a regular expression to search all +s in the string
  var lsRegExp = /\+/g;
  // Return the decoded string
  return unescape(String(psEncodeString).replace(lsRegExp, " "));
}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function gotoPage(page)
        {
        //alert(document.location+"&zone="+whichZone);
        document.location=page;
        }


var arVersion = navigator.appVersion.split("MSIE")
var version = parseFloat(arVersion[1])


function transp()
        {
                if ((version >= 5.5) && (document.body.filters))
                {
                for(var i=0; i<document.images.length; i++)
                {
                var img = document.images[i]
                var imgName = img.src.toUpperCase()
                if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
                {
                        var imgID = (img.id) ? "id='" + img.id + "' " : ""
                        var imgClass = (img.className) ? "class='" + img.className + "' " : ""
                        var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
                        var imgStyle = "display:inline-block;" + img.style.cssText
                        if (img.align == "left") imgStyle = "float:left;" + imgStyle
                        if (img.align == "right") imgStyle = "float:right;" + imgStyle
                        if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle
                        var strNewHTML = "<span " + imgID + imgClass + imgTitle
                        + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
                        + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
                        + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>"
                        img.outerHTML = strNewHTML
                        i = i-1
                }
                }
                }
        }

function productPopup(id,d)
        {
        switch(d)
                {
                case "kiss":
                        c="#ED3223";
                        break;
                case "sally":
                        c="#EC7318";
                        break;
                case "pro":
                        c="#7F001D";
                        break;
                case "broadway":
                        c="#01B6EF";
                        break;
                default:
                        c="#FFFFFF";
                        break;
                }
        w=window.open("about:blank","P","width=380,height=430,status=no,menubar=no,directories=no,toolbaar=no,resizable=no,scrollbars=no");
        doc=w.document;
        doc.write("<html><head><script language=\"JavaScript\" src=\"/pngfix.js\"></script><style>a {font-family:Arial, Helvetica, sans-serif;font-size:11px;color:black;font-weight:bold;text-decoration:none;} a:hover {text-decoration:underline;}</style><title>Popup</title></head><body style='padding:0px;margin:0px;background:"+c+";'><div style='width:100%;text-align:right;position:absolute;padding-right:25px;padding-top:15px;'><a href='javascript:window.close();'>sluit venster</a></div><table width='100%' height='425'><td align='center' valign='center'><a href='javascript:window.close();'><img border='0' src='/images/pimages/groot/"+id+"-"+d+".png' width='355' height='400'></a></td></tr></table></body></html>");

        }
