(function($) {
    $.fn.color_fade = function(opts, callback) {
      
      opts = $.extend({from:"yellow",to:"white",speed:500}, opts || {}); 
      
      $(this).css('background-color', opts['from']);            
      $(this).animate(
          { backgroundColor:opts['from'] }, 
          { duration: opts['speed'], 
            complete: function(){
              $(this).animate(
                  { backgroundColor:opts['to'] }, 
                  { duration: opts['speed'], 
                    complete: function(){
                      callback();                  
                    }
                  });
              }
          });
        
    }

})(jQuery);
