Javascript to remove spaces from a textbox value

后端 未结 7 1372
一生所求
一生所求 2020-12-17 00:44

I\'ve searched around for this a lot and can\'t find a specific example of what I\'m trying to do. Basically I want to get the value of a textbox, by the name of the text bo

7条回答
  •  执笔经年
    2020-12-17 01:00

    you can use this jQuery method http://api.jquery.com/jQuery.trim/
    val = $.trim(val); OR val = jQuery.trim(val);

提交回复
热议问题