The PHP arabic numerals converted to Chinese numerals tools.
Run this command to add this library to your composer.json
file:
composer require mouson/chinese-numerals
use Mouson\Helpers\ChineseNumericHelper;
$chinese = ChineseNumericHelper::Numeric2Chinese(123);
echo $chinese; \\ 一百二十三
$chinese = ChineseNumericHelper::Numeric2Chinese(123, true);
echo $chinese; \\ 壹佰貳拾參
一個阿拉伯數字轉換為中文數字的工具。
執行以下指令將此套件加入到 composer.json
檔案:
composer require mouson/chinese-numerals
use Mouson\Helpers\ChineseNumericHelper;
$chinese = ChineseNumericHelper::Numeric2Chinese(123);
echo $chinese; \\ 一百二十三
$chinese = ChineseNumericHelper::Numeric2Chinese(123, true);
echo $chinese; \\ 壹佰貳拾參