<?php
$f = new NumberFormatter("en", NumberFormatter::SPELLOUT);
echo ucwords($f->format($TotalCredit));
?>
I am using this code to convert number to string. This is working fine in locally but when i upload it on live server it gives a error saying "Class 'NumberFormatter' not found".
PHP Version of the server that I am using is 5.6.16. In the local server after uncommenting the line extension=ext/php_intl.dll
it runs but why i am getting this error in live server ?
The problem is that the extension needed to use that Class, is not available on Live Server.
You must do extension=ext/php_intl.dll
on Live Server.
If you cant find the php.ini
on the Live Server, I can give you 2 options:
/etc/php/
and see inside if there is any php.ini
.php_intl.dll
as extension.