提取字符串中的数字

str.replace(/[^0-9]/ig, '')

posted @ 2018-06-21 16:35  不邪  阅读(223)  评论(0)    收藏  举报