$amount = 123.456;
// for Canadian Dollars
$currency = 'CAD';
// for Canadian English
$locale = 'en_CA';
$fmt = new \NumberFormatter( $locale, \NumberFormatter::CURRENCY );
echo $fmt->formatCurrency($amount, $currency);
/* Just Do the following, */
echo money_format("%(#10n","123.45"); //Output $ 123.45
/* If Negative Number -123.45 */
echo money_format("%(#10n","-123.45"); //Output ($ 123.45)