How to display Currency in Indian Numbering Format in PHP?

You have so many options but money_format can do the trick for you. Example: $amount=”100000″; setlocale(LC_MONETARY, ‘en_IN’); $amount = money_format(‘%!i’, $amount); echo $amount; Output: 1,00,000.00 Note: The function money_format() is only defined if the system has strfmon capabilities. For example, Windows does not, so money_format() is undefined in Windows. Pure PHP Implementation – Works on … Read more

Alternative to money_format() function

If you have the Intl extension, you can use NumberFormatter::formatCurrency — Format a currency value according to the formatter rules. Example from Manual $fmt = new NumberFormatter( ‘de_DE’, NumberFormatter::CURRENCY ); echo $fmt->formatCurrency(1234567.891234567890000, “EUR”).”\n”; echo $fmt->formatCurrency(1234567.891234567890000, “RUR”).”\n”; $fmt = new NumberFormatter( ‘ru_RU’, NumberFormatter::CURRENCY ); echo $fmt->formatCurrency(1234567.891234567890000, “EUR”).”\n”; echo $fmt->formatCurrency(1234567.891234567890000, “RUR”).”\n”; Output 1.234.567,89 € 1.234.567,89 RUR 1 … Read more