var ROTATE_RATE = 9000; // number of milliseconds between item rotation
 
function rotateContent(items, index) {
	var item = $(items[index++]);
	
	// reset index when we reach the last item
	if (index == items.length) {
		index = 0;
	}
	
	// move the item to the more-content container
	$('#more-content').empty().append(item);
	
	// fade item in
	item.fadeIn('normal', function() {
		// set timer to fade item out and display the next one
		setTimeout(function() {
			item.fadeOut('normal', function() {
				rotateContent(items, index);
			});
		}, ROTATE_RATE);
	});
}

$(function() {
	// hide the divs we use as content for the "want more?" box
	$('div.testimonials').hide();
	rotateContent($('div.testimonials'), 0);
});