Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript remove non numeric chars from string keep dot

var s = "-12345.50 €".replace(/[^d.-]/g, ''); // gives "-12345.50"
 
PREVIOUS NEXT
Tagged: #javascript #remove #numeric #chars #string #dot
ADD COMMENT
Topic
Name
6+8 =