标签: javascript
举一个例子To text string只包含alpha numaric,$和_使用javascript
答案 0 :(得分:1)
var regex = / [0-9a-zA-Z $ _] + / ig
有关详细信息,请参阅此处
https://developer.mozilla.org/en-US/docs/JavaScript/Guide/Regular_Expressions