$(document).ready(function() {
				
    $('.viewport').carousel('#simplePrevious', '#simpleNext');  
});
			
//The auto-scrolling function
function slide(){
    $('#simpleNext').click();
}
//Launch the scroll every 2 seconds
var intervalId = window.setInterval(slide, 5000);			
//On user click deactivate auto-scrolling
$('#previous, #simpleNext').click(
    function(event){
        if(event.originalEvent){
            window.clearInterval(intervalId);
        }
    }
    );
