(function($){
 $.fn.jquote = function(options) {

  var defaults = {
   bquoteclass: "jquote",
   srcclass: "source"
   };
   
  var options = $.extend(defaults, options);
    
  return this.each(function() {
        //the magic. Remember access options by using options.optionname!
        //jQuote - originally written by Jack Franklin December 2008.
        //Rewritten to correct small bugs and better, cleaner code Feb 2009. 2 months late!
        //RELEASED TO THE WORLD = 14th Feb 2009.
        //Visit jackfranklin.co.uk/jquote for help.
        //Follow @jQuote on Twitter - twitter.com/jquote.
        var opentag = "<blockquote class=\"" + options.bquoteclass + "\">";
        var thequote = $("span.quote").text();
        var end = "</blockquote>";
        var source1 = "<span class=\"" + options.srcclass + "\">";
        var source2 = "</span>";
        var person = $("span.quote").attr("title");
        $("span.quote").after(opentag+thequote+source1+person+source2+end);
        
        
  });
 };
})(jQuery);
