Write a PHP script to remove nonnumeric characters except comma and dot.
Sample string : '$123,34.00A'
<?php $str1 = "$12,334.00A"; echo preg_replace("/[^0-9,.]/", "", $str1)."\n"; ?>
Sample Output:
12,334.00
total answers (1)
start bookmarking useful questions and collections and save it into your own study-lists, login now to start creating your own collections.
Sample Output:
need an explanation for this answer? contact us directly to get an explanation for this answer