
	
	window.addEvent('domready', function() {
		
		//variables for making things more simple below
		var itemsHolder = $('container');
		var myItems = $$('.item');
		var thePrevBtn = $('prev_btn');
		var theNextBtn = $('next_btn');
		
		
		//create an instance of the slider, and start it up
		var mySlider = new SL_Slider({
			slideTimer: 6000,
			isPaused: false,
			container: itemsHolder,
			items: myItems,
			prevBtn: thePrevBtn,
			nextBtn: theNextBtn
		});
		mySlider.start();
		
		
		//adding a little animated rollover highlight to the play and prev/next buttons
		var origBkgdColor = thePrevBtn.getStyle('');
		var newBkgdColor = "";
		var btnArray = new Array(thePrevBtn, theNextBtn);
		
		btnArray.each(function(e, i){
			e.set('tween', {duration: 350, transition: 'cubic:out', link: 'cancel'});
			e.addEvents({ 
				'mouseenter' : function() {
					this.tween('background-color', newBkgdColor);
				},
				'mouseleave' : function() {
					this.tween('background-color', origBkgdColor);
				}
			});
		});
					 
	});
	
