3v4l.org

run code in 500+ PHP versions simultaneously
<?php $price = "one price $1,234,567.223 and some other price $60"; preg_match_all('/([\d\.,]+)/',$price,$match); Var_dump($match); $formatter = new NumberFormatter('en_US', NumberFormatter::CURRENCY); Var_export($formatter->parseCurrency($price, $curr));

preferences:
43.59 ms | 1494 KiB | 5 Q