dev-master
9999999-devLibrary to convert Latin numbers to Arabic and vice versa
The Requires
- php ^7.0
The Development Requires
by Meezaan-ud-Din Abdu Dhil-Jalali Wal-Ikram
Wallogit.com
2017 © Pedro Peláez
Library to convert Latin numbers to Arabic and vice versa
بِسْمِ اللهِ الرَّحْمٰنِ الرَّحِيْمِ, (*2)
This library helps convert between latin and arabic numerals and vice versa., (*3)
To install:, (*4)
composer require meezaan/arabic-numbers
To use the library in your apps, make sure the composer autoload file is already included. Then:, (*5)
use ArabicNumbers\Numbers; // Latin to Arabic $arabic = Numbers::latinToArabic(157); // returns ١٥٧ // Arabic to latin $latin - Numbers::arabicToLatin(١٥٧); // returns 157 // Arabic to HTML $html = Numbers::ArabicToHtml(١٥٧); // returns ١٥٧
These are included in the tests folder. To run them, make sure you've already run composer install. Then:, (*6)
php vendor/bin/phpunit --bootstrap vendor/autoload.php tests/
Happy days., (*7)
Library to convert Latin numbers to Arabic and vice versa