kartik\helpers\Enum::numToWords PHP Method

numToWords() public static method

Example: ~~~ echo Enum::numToWords(21909); returns: twenty one thousand nine hundred and nine ~~~
public static numToWords ( double $num ) : string
$num double the source number
return string
    public static function numToWords($num)
    {
        $num = (int) $num;
        // make sure it's an integer
        if ($num < 0) {
            return Yii::t('kvenum', 'minus') . ' ' . static::convertTri(-$num, 0);
        }
        if ($num == 0) {
            return Yii::t('kvenum', 'zero');
        }
        return static::convertTri($num, 0);
    }