Download the PHP package martinjoiner/ordinal-number without Composer
On this page you can find all versions of the php package martinjoiner/ordinal-number. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download martinjoiner/ordinal-number
More information about martinjoiner/ordinal-number
Files in martinjoiner/ordinal-number
Download martinjoiner/ordinal-number
More information about martinjoiner/ordinal-number
Files in martinjoiner/ordinal-number
Vendor martinjoiner
Package ordinal-number
Short Description Converts numbers to a human readable ordinal form eg. 'first', 'second' or even 'Three thousand five hundred sixty first'
License MIT
Package ordinal-number
Short Description Converts numbers to a human readable ordinal form eg. 'first', 'second' or even 'Three thousand five hundred sixty first'
License MIT
Please rate this library. Is it a good library?
Informations about the package ordinal-number
Ordinal Number
A PHP package for converting numbers to a human readable sentence of it's ordinal form eg. 'first', 'second' or even 'Three thousand five hundred and sixty first'
Latest release supports numbers in the range 1 - 9999.
Installation
Recomended installation via Composer:
See library page on Packagist https://packagist.org/packages/martinjoiner/ordinal-number
Usage example
convert() method parameters
Required parameters
- num {integer} A number to be converted (in the range of 1 - 9999)
Optional parameters
- appendAnd {boolean} - Default: false - Places the word 'and' before the final 2 parts if number above 101 or higher (eg. One hundred and first). Added to support both American and European versions of English language.
- titleCase {boolean} - Default: false - Capitalises the first letter
To see some working examples simply run index.php
Testing
Tests are written in PHPUnit https://phpunit.de/
All versions of ordinal-number with dependencies
PHP Build Version
Package Version
Requires
php Version
>=5.3.0
The package martinjoiner/ordinal-number contains the following files
Loading the files please wait ....