        $(document).ready(function(){
            setInterval("slidePix()", 5000);
        });
        var count = 1;
        function slidePix() {
            var curPic = $('#flipPix div.act');
            var nextPic = curPic.next();
            if (nextPic.length == 0){ // Tests to see if their are more pics
                nextPic = $('#flipPix div:first'); // If not start at beginning
            }
	    
            curPic.removeClass('act').addClass('prev'); // Change the class
	 
	    if(count == 0){
		nextPic.css({opacity:0.0, width:"0px",height:"0px"}).addClass('act').animate({opacity:1.0,width:"950px",height:"251px"}, 1000,
		function() {
		    curPic.removeClass('prev');
		    count = 1;
		});
		
	    }else if (count == 1){
		    nextPic.css({opacity:0.0, width:"0px"}).addClass('act').animate({opacity:1.0,width:"950px"}, 1000,
		    function() {
			curPic.removeClass('prev');
		    });
		    count = 2;
		}else if (count == 2){
			nextPic.css({opacity:0.0, height:"0px"}).addClass('act').animate({opacity:1.0,height:"251px"}, 1000,
			function() {
			    curPic.removeClass('prev');
			});
			count = 0;
		    }
		}
            
	    
	    
