How to remove dollar format with regex

前端 未结 8 1917
北荒
北荒 2021-01-21 02:42

I am trying to remove the dollar format from the string \'$1,109,889.23\'. I tried using a regular expression with:

\"[^\\\\d]\" 

but then I ge

8条回答
  •  后悔当初
    2021-01-21 02:52

    How about just doing a search and replace for , and $?

    but if you're going to do it.

    [^\d.]+

提交回复
热议问题