Event.observe(window, 'load', function() 
{
	
	
	if(typeof sIFR == "function"){
	    
		
//		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto.swf", sSelector: ".nav", sColor: "#FFFFFF", sWmode: "transparent", sFlashVars: "offsetLeft=5"}));	    
//		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto.swf", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
//		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto.swf", sSelector: ".ibtitle", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
//		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto.swf", sSelector: ".ibsubtitle", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
//		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto.swf", sSelector: ".vacatures", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
//	    sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto.swf", sColor: "#FFFFFF", sWmode: "transparent", sFlashVars: "offsetLeft=5"}));
//	    sIFR.replaceElement("h3", named({sFlashSrc: "/libraries/sifr/netto.swf", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));
//	    sIFR.replaceElement("h4", named({sFlashSrc: "/libraries/sifr/netto.swf", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));

		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".nav", sColor: "#FFFFFF", sWmode: "transparent", sFlashVars: "offsetLeft=5"}));	    
		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".h1-initiatief-realiseren", sColor: "#FF0000", sWmode: "transparent", sFlashVars: ""}));	    
		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".h1-initiatief-helpen", sColor: "#009d50", sWmode: "transparent", sFlashVars: ""}));	    
		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".h1-advies-en-kennis", sColor: "#5b5099", sWmode: "transparent", sFlashVars: ""}));	    
		sIFR.replaceElement("h1", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    

		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".white", sColor: "#FFFFFF", sWmode: "transparent", sFlashVars: "offsetLeft=15"}));	    
		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".ibtitle", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".ibsubtitle", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
		sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sSelector: ".vacatures", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));	    
	    //sIFR.replaceElement("h2", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sColor: "#FFFFFF", sWmode: "transparent", sFlashVars: "offsetLeft=5"}));
	    sIFR.replaceElement("h3", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));
	    sIFR.replaceElement("h4", named({sFlashSrc: "/libraries/sifr/netto_bold.swf", sColor: "#0098c3", sWmode: "transparent", sFlashVars: ""}));
	    
	    
	};
	
	
	newNavigator = new NavigatorCollection();
	newNavigator.getNavigator(
	{
		'id'				: "topmenu",
		'submenu'			: "downblind"
	});
	
	if($('link_nieuws'))
	{
		Event.observe('link_nieuws', 'click', function(event)
		{
			if($('kop_nieuws').hasClassName("title_inactive"))
			{
				//new Effect.Move($('button_1'), { x: 25, y: 0, mode: 'absolute', duration: 0.2  }); 
				//return false;
				$('kop_nieuws').removeClassName("title_inactive");
				$('kop_nieuws').addClassName("title");
				//$('newsitems').show();
				Effect.BlindDown('newsitems', { queue: { position: 'end', scope: 'menuxscope', limit: 1 } }); 
				return false;
			}
			else
			{
				$('kop_nieuws').removeClassName("title");
				$('kop_nieuws').addClassName("title_inactive");
				Effect.BlindUp('newsitems', { queue: { position: 'end', scope: 'menuxscope', limit: 1 } }); 
				return false;
			}
			
		});
	}
	
	if($('link_agenda'))
	{
		Event.observe('link_agenda', 'click', function(event)
		{
			if($('kop_agenda').hasClassName("title_inactive"))
			{
				//new Effect.Move($('button_1'), { x: 25, y: 0, mode: 'absolute', duration: 0.2  }); 
				//return false;
				$('kop_agenda').removeClassName("title_inactive");
				$('kop_agenda').addClassName("title");
				Effect.BlindDown('agendaitems', { queue: { position: 'end', scope: 'menuxscope', limit: 1 } }); 
				return false;
			}
			else
			{
				$('kop_agenda').removeClassName("title");
				$('kop_agenda').addClassName("title_inactive");
				Effect.BlindUp('agendaitems', { queue: { position: 'end', scope: 'menuxscope', limit: 1 } }); 
				return false;
			}
		});
	}
	
	if($('slide-images'))
	{
		init();
	}
	
});

	var delay = 8000;
	var start_frame = 0;
	
	function init() {
		var lis = $('slide-images').getElementsByTagName('li');
		
		for( i=0; i < lis.length; i++){
			if(i!=0){
				lis[i].style.display = 'none';
			}
		}
		end_frame = lis.length -1;
		
		start_slideshow(start_frame, end_frame, delay, lis);
		
		
	}
	
	
	
	function start_slideshow(start_frame, end_frame, delay, lis) {
		setTimeout(fadeInOut(start_frame,start_frame,end_frame, delay, lis), delay);
	}
	
	
	function fadeInOut(frame, start_frame, end_frame, delay, lis) {
		return (function() {
			lis = $('slide-images').getElementsByTagName('li');
			Effect.Fade(lis[frame]);
			if (frame == end_frame) { frame = start_frame; } else { frame++; }
			lisAppear = lis[frame];
			setTimeout("Effect.Appear(lisAppear);", 0);
			setTimeout(fadeInOut(frame, start_frame, end_frame, delay), delay + 1850);
		})
		
	}

function SwapImage(element)
{
	this.active = element;
}

	SwapImage.prototype.swap = function(element, id, src)
	{
		if (this.active.id != element.id)
		{
			element.className = 'active';
			
			document.getElementById(id).src = src;
			
			this.active.className = '';
			this.active = element;
		}
	}
