(function(jQuery) {
  jQuery.fn.rotate = function() {
    var container = jQuery(this);
    var totale = container.find("div").size();
    var current = 0;
    var i = setInterval(function() {
      if (current >= totale) current = 0;
      container.find("div").filter(":eq("+current+")").fadeIn("slow").end().not(":eq("+current+")").fadeOut("slow");
      current++;
    }, 8000);
    return container;
  };
})(jQuery);
