daha kolayını yazalım

$cc = "50.00 dolar";
$metin = preg_replace('/[^.%0-9]/', '', $cc);
echo $metin;