(function($){
  $.extend($.fn,{
color:function(options)
{
var options=$.extend({bcolor:"white",fcolor:"black"},options);
return this.each(function(){
  $(this).css("color",options.bcolor);
  $(this).css("color",options.fcolor);
  
  });
}

})
  
  })(jquery);
  

解决方案 »

  1.   

    jquery(最后)   应该是  jQuery    q是大写的$(this).css("color",options.bcolor);  
    $(this).css("color",options.fcolor);
    这两句话都是改文本颜色  第一个应该改背景颜色吧? background-color调用:
    $("#t").color({
       bcolor:"red",fcolor:"green"
    });
      

  2.   

    报的错是 color is not a  function
      

  3.   

    不知道你是怎么测试的
    IE9  火狐下测试没问题:
    引用库
    <script type="text/javascript" src="http://code.jquery.com/jquery-1.7.2.min.js"></script>
    代码:(function($){
        $.extend($.fn,{
            color:function(options){
                var options=$.extend({bcolor:"white",fcolor:"black"},options);
                return this.each(function(){
                    $(this).css("background",options.bcolor);
                    $(this).css("color",options.fcolor);    
                });
            }                  
        })
    })(jQuery);
    $(function(){
        $("#t").color({
            bcolor:"red",fcolor:"white"
        });
    });