var initMultiBox
window.addEvent('domready', function() {
	var header = new Swiff('../flash/header.swf', {
		id: 'headerFlash',
		container: 'illustration',
		width: 770,
		height: 229,
		params: {
			wmode: 'window',
			majorversion: '7',
			build:"0", 
			loop:"false", 
			menu:"false", 
			xi:"false"
		}
	});	
	if ($('scroller-items')) {
		new SlideItMoo({
			overallContainer: 'scroller-container_outer',
			elementScrolled: 'scroller-container_inner',
			thumbsContainer: 'scroller-items',		
			itemsVisible:6,
			elemsSlide:6,
			itemsSelector: '.scroller_element',
			itemWidth: 115,
			duration: 50,
			mouseWheelNav: true,
			transition: Fx.Transitions.expo,
			showControls:1
		});
	}
	initMultiBox = new multiBox({
		mbClass: '.mb',//class you need to add links that you want to trigger multiBox with (remember and update CSS files)
		container: $(document.body),//where to inject multiBox
		useOverlay: true,//use a semi-transparent background. default: false;
		maxSize: {w:650, h:421},//max dimensions (width,height) - set to null to disable resizing
		addDownload: false,//do you want the files to be downloadable?
		addRollover: true,//add rollover fade to each multibox link
		addOverlayIcon: false,//adds overlay icons to images within multibox links
		addChain: false,//cycle through all images fading them out then in
		recalcTop: true,//subtract the height of controls panel from top position
		showControls: false,
		addTips: false,//adds MooTools built in 'Tips' class to each element (see: http://mootools.net/docs/Plugins/Tips)
		onOpen: function test(){
			$$('.mb').each(function(el) {  				
				el.set('href',el.get('href').replace('.html','.html?ajax=true&DynamicDir=../&')); 
			});
		},
		onClose: function test(){
			$$('.mb').each(function(el) {  				
				el.set('href',el.get('href').replace('.html?ajax=true&DynamicDir=../&','.html')); 
			});
		}
	}); 
	if($('togglebar')) {
		$('togglebar').addEvent('click', function(){
			var revealer = new Fx.Reveal($('revealer'), {
				onHide:function(){
					if (Browser.Engine.trident) location.reload();
				}
			}).toggle();
		});
	}
	
});