I have the following regex:
preg_match_all('/([0-9]+[\.]*[0-9]*[\,.]*[0-9]*)/', $string, $matches)
If I get a string:
1 - João da Silva number 123456 with the value of R $: 6,298.65
I have a return:
array (size=27)
0 => string '1' (length=1)
1 => string '123456' (length=5)
2 => string '6.298,65' (length=8)
However, I would like to return only the actual value: 6,298.65