Automating a slideshow and stopping it with a click.

Automating a slideshow and stopping it with a click.

Hello,
 
I have a Portfolio section of a website I'm working on. I have the page for the most part working perfectly. I wanted to add one more effect to it. I wanted to page to run in a slideshow automatically for 5 seconds on each picture and continue to loop until someone clicks on a thumbnail below which would stop the slideshow and display the larger picture of what they clicked on. If you take a look at the page this might make more sense.
 
 
This is one of the pages I wanted to add this effect to. I have also added to here the jquery function that I believe this would need to be added to.
 
  1. $(document).ready(function(){
     $('.mini a').click(function(e){
      e.preventDefault();
      $('div.main img').fadeOut('fast');
      var pic = new Image();
     $(pic).load( function() {
      $(pic).hide();
      $('div.main').append(pic);
      $(pic).animate({opacity: 1.0}, 'fast');
      $(pic).fadeIn('slow');
     }).attr({ "src": $(this).attr('href') });
     });
    });











 
 
Any help would be greatly appreciated.
 
Thanks.