I am getting this PHP error in PHP7. Do you know how to fix it?
Deprecated: Function money_format() is deprecated in was last modified: August 15th, 2022 by
1 Answers
Best Answer
Update to this new way. You can put your variable where it says -0.99 and that is all. 🙂
$formatter = new NumberFormatter('en_US', NumberFormatter::CURRENCY);
echo $formatter->formatCurrency(-0.99, 'USD'), PHP_EOL;
Answer for Deprecated: Function money_format() is deprecated in was last modified: August 15th, 2022 by