

var $j = jQuery.noConflict();


$j(document).ready(function(){


	$j('#slideshow DIV.backimagecont').css("opacity","0");
	$j('#slideshow DIV.backimagecont:first-child').css("opacity","1");
	



	setInterval(function() {
      // Do something every 2 seconds
	  
	  var $active = $j('#slideshow DIV.active');
	
	  var $lastactive = $j('#slideshow DIV.last-active');

		if ( $active.length == 0 ) $active = $j('#slideshow DIV:last');
	
		// use this to pull the images in the order they appear in the markup
		var $next =  $active.next().length ? $active.next()
			: $j('#slideshow DIV:first');
	
		$active.addClass('last-active');
	
		$next.css({opacity: 0.0})
			.addClass('active')
			.animate({opacity: 1.0}, 1000, function() {
													
													
													
				$active.removeClass('active last-active');
				//$active.removeClass('active last-active').animate({ opacity: 0.0 }, 800, function() { });
		});
	  $active.animate({ opacity: 0.0 }, 1000, function() { });
	  
	}, 5500);

});


//$('#book').fadeTo('slow', 0.5, function() {

/*

var $j = jQuery.noConflict();


$j(document).ready(function(){


	



	setInterval(function() {
      // Do something every 2 seconds
	  
	  var $active = $j('#slideshow IMG.active');
	
		if ( $active.length == 0 ) $active = $j('#slideshow IMG:last');
	
		// use this to pull the images in the order they appear in the markup
		var $next =  $active.next().length ? $active.next()
			: $j('#slideshow IMG:first');
	
		$active.addClass('last-active');
	
		$next.css({opacity: 0.0})
			.addClass('active')
			.animate({opacity: 1.0}, 800, function() {
				$active.removeClass('active last-active');
		});
	  
	  
	}, 3500);

});*/
