Have you ever had a number that you need to convert to a more readable number? Maybe get it ready to be displayed like money?
PHP does not really have a way to do this, but Rails does. I implemented the number_with_delimiter helper from Rails to PHP.
PHP:
-
/**
-
* Formats a number grouped by the thousands.
-
*
-
* @return string
-
* @author Justin Palmer
-
**/
-
function number_with_delimiter($num, $delimiter=',', $seperator='.')
-
{
-
: $ret = $ret;
-
}
I hope it helps.
Later
Development php