var currentSlide = 1;
var totalSlides = 0;

function changeSlide()
{
	$('#testimonial-' + currentSlide).fadeOut(700);
	currentSlide = (currentSlide == totalSlides) ? 1 : currentSlide + 1;
	$('#testimonial-' + currentSlide).fadeIn(1000);
}

function countSlides()
{
	totalSlides = 0;
	$('#testimonial-loader > div').each(function(item){
		totalSlides++;
	});
}

$(document).ready(function() {
	countSlides();
	changeSlide();
	var interval = window.setInterval(changeSlide, 7000);
});
