if (is_array($accept)) {
$accept = implode(', ', $accept);
}
- $accept = str_replace('*.', '.', $accept);
- return $accept;
+ return str_replace('*.', '.', $accept);
}
}
if ($(this).closest('.sample').length > 0) {
return;
}
- var e=$(this);
- var options={
+ var e = $(this);
+ var options = {
preferredFormat: "hex3",
showInitial: true,
showInput: true,
allowEmpty: true,
showAlpha: $(this).attr('data-show-alpha') === 'true',
- move:function(color){
+ move: function (color) {
+ if (null === 'color') {
+ color = '';
+ }
e.val(color.toString());
e.trigger('change');
},
- dragend:function(color){
+ dragend: function (color) {
e.val(color.toString());
e.trigger('change');
}