setlocale(LC_MONETARY, 'en_US');
$str = money_format('%=*#4.4n',163.17852837291);
返回. $**163.1785
_$str
我想打印$✪✪163.1785
,而不是。
我该如何解决这个问题?
setlocale(LC_MONETARY, 'en_US');
$str = money_format('%=*#4.4n',163.17852837291);
返回. $**163.1785
_$str
我想打印$✪✪163.1785
,而不是。
我该如何解决这个问题?
You could define a specific-function this way:
function m_money_format($f, $s)
{
return str_replace("*", "&\#x272a;", money_format($f,$s));
}
setlocale(LC_MONETARY, 'en_US');
$str = m_money_format($f, $s);
So you can call the function whenever you need it, in every part of you code