<!-- algemeen -->
function close_window() {
    window.close();
}
function print_window() {
    window.print();
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

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_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

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 MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

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 MM_showHideLayers() { //v6.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}

function switchMenuLayer(linkElement, layerId) {
	var element = MM_findObj(layerId);
	if(element != null) {
		if(element.style.display == 'block') {
			linkElement.className = 'closed';
			element.style.display = 'none';
		} else {
			linkElement.className = 'open';
			element.style.display = 'block';
		}
	}
}

function switchReadMoreContent(showLinkElementId, hideLinkElementId, readMoreContentId, showContent) {
	var showLinkElement = MM_findObj(showLinkElementId);
	var hideLinkElement = MM_findObj(hideLinkElementId);
	var readMoreContentElement = MM_findObj(readMoreContentId);
	
	if(showLinkElement != null && hideLinkElement != null && readMoreContentElement != null) {
		showLinkElement.style.display = 'block';
		hideLinkElement.style.display = 'none';
		if(showContent) {
			readMoreContentElement.style.display = 'block';
		} else {
			readMoreContentElement.style.display = 'none';
		}
	}
	
}
//sitemap


	function expandBranche(id, folderstyle) {
		obj = MM_findObj("div_" + id);
		img_cross = document.images["cross_" + id];
		//img_folder = document.images["folder_" + id];
		if (obj.style.display == "none" || obj.style.display == '') {
			obj.style.display = "block";
			img_cross.src = "/furniture/images/button_sitemappijl" + folderstyle + "_down.gif";
		}
		else {
			obj.style.display = "none";
			img_cross.src = "/furniture/images/button_sitemappijl" + folderstyle + ".gif";
		}
	}


var moviewin = null;

function launchmoviegen(videoname,moviewidth,movieheight){

//if movie window exists

   if(moviewin != null)
   {

   try
   {
      if(moviewin.document != null)
      {

            var htmlString=
            "<OBJECT CLASSID='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' id=robodemo WIDTH='"+moviewidth+"' HEIGHT='"+movieheight+"' CODEBASE='http://active.macromedia.com/flash5/cabs/swflash.cab#version=5,0,0,0'> "+
            "<PARAM NAME=movie VALUE='" + videoname + "'> "+
            "<PARAM NAME=play VALUE=true> "+
            "<PARAM NAME=loop VALUE=0>"+
            "<PARAM NAME=quality VALUE=high>"+
            "<EMBED name=robodemo SRC='" + videoname + "' WIDTH="+moviewidth+" HEIGHT="+movieheight+
            "loop=0 quality=high "+
            "TYPE='application/x-shockwave-flash' "+
            "swLiveConnect=true "+
            "PLUGINSPAGE='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash'>"+
            "</EMBED>"+
            "</OBJECT>";
   
            moviewin.document.all.mymovie.innerHTML = htmlString;
      }
   }
    catch(e){moviewin = null; launchmoviegen(videoname,moviewidth,movieheight); return;}

   }

//if no movie window

   else
   {
   moviewin = window.open("","mediasurfacemovie","scrollbars=no, fullscreen=yes, resizeable=yes")
   
   var htmlString=
   "<HTML><HEAD><TITLE>Morello Demo</TITLE><LINK REL=StyleSheet HREF='hellomorello.css' TYPE='text/css' MEDIA='screen'></head> "+
   "<BODY topmargin='9' leftmargin='0' bgcolor='#000000' scroll='no' onLoad='window.document.robodemo.focus();'><center><table height='100%'><tr height='100%'><td height='100%' valign='center'> "+
   "<span id=mymovie><OBJECT CLASSID='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' id=robodemo WIDTH='"+moviewidth+"' HEIGHT='"+movieheight+"' CODEBASE='http://active.macromedia.com/flash5/cabs/swflash.cab#version=5,0,0,0'> "+
   "<PARAM NAME=movie VALUE='" + videoname + "'> "+
   "<PARAM NAME=play VALUE=true> "+
   "<PARAM NAME=loop VALUE=0>"+
   "<PARAM NAME=quality VALUE=high>"+
   "<EMBED name=robodemo SRC='" + videoname + "' WIDTH="+moviewidth+" HEIGHT="+movieheight+
   "loop=0 quality=high "+
   "TYPE='application/x-shockwave-flash' "+
   "swLiveConnect=true "+
   "PLUGINSPAGE='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash'>"+
   "</EMBED>"+
   "</OBJECT></span>"+
   "<table align='left'><tr><td class='Footer'>© 1997 - 2006 Mediasurface Europe Ltd, United Kingdom and its worldwide subsidiary companies.</td></tr></table></td></tr></table></center>"+
   "</BODY></HTML>";

   moviewin.document.open();
   moviewin.document.write(htmlString);
   moviewin.document.close();
   }
}

function launchmovie(vidname){
   launchmoviegen(vidname,1014,713);
   moviewin = null;
}
function launchmovie800_600(vidname){
   launchmoviegen(vidname,800,600);
   moviewin = null;
}

function pageTitle(tmpValue )
{
    // mike begin DOTCOM-308, DOTCOM-338
    
    tmpValue = tmpValue.replace(/&/ig, "%26");
    tmpValue = tmpValue.replace(/"/ig, "&quot;");
    
    // mike eind DOTCOM-308, DOTCOM-338
    document.write('<div class="print_flash"><object name="' + tmpValue + '" type="application/x-shockwave-flash" data="/furniture/swf/pageTitle.swf" width="100%" height="25" align="middle">\n');
    document.write('<param name="Movie" value="/furniture/swf/pageTitle.swf"/>\n');
    document.write('<param name="bgcolor" value="FFFFFF"/>\n');
    document.write('<param name="wmode" value="transparent"/>\n');
    document.write('<param name="FlashVars" value="&amp;FVTitle=' + tmpValue + '&amp;FVFont=Arial&amp;FVFontSize=20&amp;FVTitleColor=8B9EAD"/>\n');
    document.write('<div class="pageTitle">' + tmpValue + '</div>');
    //document.write('<h2 class="pageTitle">' + tmpValue + '</h2>');
    document.write('</object></div>\n');
}

function subjectTitle(tmpValue )
{
    // mike begin DOTCOM-308, DOTCOM-338
    
    tmpValue = tmpValue.replace(/&/ig, "%26");
    tmpValue = tmpValue.replace(/"/ig, "&quot;");
    
    // mike eind DOTCOM-308, DOTCOM-338
    document.write('<div class="print_flash"><object name="' + tmpValue + '" type="application/x-shockwave-flash" data="/furniture/swf/subjectTitle.swf" width="100%" height="40" align="middle">\n');
    document.write('<param name="Movie" value="/furniture/swf/subjectTitle.swf"/>\n');
    document.write('<param name="bgcolor" value="FFFFFF"/>\n');
    document.write('<param name="wmode" value="transparent"/>\n');
    document.write('<param name="FlashVars" value="&amp;FVTitle=' + tmpValue + '&amp;FVFont=Arial&amp;FVFontSize=30&amp;FVTitleColor=B0232A"/>\n');
    //document.write('<div class="subjectTitle">' + tmpValue + '</div>\n');
    document.write('<h1 class="subjectTitle">' + tmpValue + '</h1>\n');
    document.write('</object></div>\n');
}

function H1(tmpValue)
{
    // mike begin DOTCOM-308, DOTCOM-338
    
    tmpValue = tmpValue.replace(/&/ig, "%26");
    tmpValue = tmpValue.replace(/"/ig, "&quot;");
    
    // mike eind DOTCOM-308, DOTCOM-338
    document.write('<div class="print_flash"><object name="' + tmpValue + '" type="application/x-shockwave-flash" data="/furniture/swf/H2.swf" width="100%" height="25" align="middle">');
    document.write('<param name="Movie" value="/furniture/swf/H1.swf"/>');
    document.write('<param name="bgcolor" value="FFFFFF"/>');
    document.write('<param name="wmode" value="transparent"/>');
    document.write('<param name="FlashVars" value="&amp;FVTitle=' + tmpValue + '&amp;FVFont=Arial&amp;FVFontSize=20&amp;FVTitleColor=666666"/>');
    document.write('<h1>' + tmpValue + '</h1>');
    document.write('</object></div>');
}

function H6(tmpValue)
{
    // mike begin DOTCOM-308, DOTCOM-338
    
    tmpValue = tmpValue.replace(/&/ig, "%26");
    tmpValue = tmpValue.replace(/"/ig, "&quot;");
    
    // mike eind DOTCOM-308, DOTCOM-338
    document.write('<div class="print_flash"><object name="' + tmpValue + '" type="application/x-shockwave-flash" data="/furniture/swf/H2.swf" width="100%" height="22" align="middle">');
    document.write('<param name="Movie" value="/furniture/swf/H6.swf"/>');
    document.write('<param name="bgcolor" value="FFFFFF"/>');
    document.write('<param name="wmode" value="transparent"/>');
    document.write('<param name="FlashVars" value="&amp;FVTitle=' + tmpValue + '&amp;FVFont=Arial&amp;FVFontSize=18&amp;FVTitleColor=666666"/>');
    document.write('<h6>' + tmpValue + '</h6>');
    document.write('</object></div>');
}


