jquery.simplecolorpicker.js
function(color) {
      var self = this;

      var $colorSpan = self.$colorList.find('> span.color').filter(function() {
        return $(this).data('color').toLowerCase() === color.toLowerCase();
      });

      if ($colorSpan.length > 0) {
        self.selectColorSpan($colorSpan);
      } else {
        console.error("The given color '" + color + "' could not be found");
      }
    }
function(color) {
      var self = this;

      var $colorSpan = self.$colorList.find('> span.color').filter(function() {
        return $(this).data('color').toLowerCase() === color.toLowerCase();
      });

      if ($colorSpan.length > 0) {
        self.selectColorSpan($colorSpan);
      } else {
        console.error("The given color '" + color + "' could not be found");
      }
    }
function ( color ) { var self = this ; var $colorSpan = self . $colorList . find ( '> span.color' ) . filter ( function ( ) { return $ ( this ) . data ( 'color' ) . toLowerCase ( ) === color . toLowerCase ( ) ; } ) ; if ( $colorSpan . length > 0 ) { self . selectColorSpan ( $colorSpan ) ; } else { console . error ( "The given color '" + color + "' could not be found" ) ; } }
Changes the selected color.

@param color the hexadecimal color to select, ex: '#fbd75b'
Changes the selected color .