/* -- START FLASH --*/
addLoadEvent(function(){
	if(typeof SWFObject == "function"){
		if($('banner')){
			var so = new SWFObject(siteinfo['url']+"/www/swf/mv_ani.swf", "homeswf", "105", "272", "8", "#FFFFFF");
			so.addParam("menu", "false");		
			so.addParam("wmode", "opaque");		
			so.write("banner");
		}
		if($('intro')){
			var so = new SWFObject(siteinfo['url']+"/www/swf/intro.swf", "homeswf", "906", "265", "8", "#FFFFFF");
			so.addParam("menu", "false");		
			so.addParam("wmode", "opaque");		
			so.write("intro");
		}		
	}
	

});
/* -- END FLASH --*/

/* -- START Productsearch --*/
addLoadEvent(function(){
	if(typeof populate_menu == "function"){
		populate_menu();
	}
});
/*** AJAX ***/
addLoadEvent(function(){
	if(typeof Search == "function"){
		if(!$('dd')){
			var search = new Search('zoek_criteria',{
				ajax_url:'../www/scripts/ajax_reqs.php',
				ajax_container: 'resultaatbox',
				ajax_parameters: {
					t:"search",
					sleep: 2
				},
				submitButton:'button.zoek',
				submitOnEnter: true,
				addButton:'bereken_cal',
				delButton:'td.trash a'
			});
		}else{
			var search = new Search_Ext('zoek_criteria',{
				ajax_url:'../www/scripts/ajax_reqs.php',
				ajax_container: 'resultaatbox',
				ajax_parameters: {
					t:"search",
					sleep: 2
				},
				submitButton:'button.zoek',
				submitOnEnter: true,
				addButton:'bereken_cal',
				delButton:'td.trash a',
				dagelijksButton:'input.every_day',
				ajax_toevoegen: {
					session_id: 'session_id',
					user_id: 'id',
					timestamp: 'timestamp',
					dd: 'dd'
				}
			});
		}
	}
});
/* -- END Productsearch --*/

/* -- START Uitschuiven --*/
addLoadEvent(function(){
	if(typeof Slide == "function"){
		 zoekbox_slide = new Slide('zoekbox',{
				trigger: 'a.zoekOpTrefwoord',
				close: 'a.close'
			});
	}
});
addLoadEvent(function(){
	if(typeof Slide == "function"){
		resultaat = new Slide('resultaatbox',{
				//trigger: 'button.zoek',
				close: 'a.close',
				transition: Effect.Transitions.linear
			});
	}
});
/* -- END Uitschuiven --*/

/* -- START Carousel --*/
addLoadEvent(function(){
	if(typeof Glider == "function"){
		glider = new Glider('list', {
			duration:0.2,
			autoGlide: true,
			frequency: 1,
			initialSection: 'section1',
			leftButton: 'scrollLeft',
			rightButton: 'scrollRight'	
		});
	}
})
/* -- END Carousel --*/
/* -- START animatie --*/
addLoadEvent(function(){
	if(typeof slideshow == "function"){
		slideshow = new slideshow('man_vrouw_ani', {
			duration:1,
			images: Array(
				'../images/animaties/man.png',
				'../images/animaties/vrouw_f2.png'
			)
		});
	}
})
/* -- END animatie --*/
