jQuery去空格 /** * 去空格 */ jQuery.fn.deng_trim = function () { $(this).val($(this).val().replace(/[\s]/g,'')) };