lightools / company-id-validator
Simple Czech company ID validator.
Installs: 6 681
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: >=5.3
Requires (Dev)
- nette/tester: 1.*
This package is auto-updated.
Last update: 2022-10-04 10:17:46 UTC
README
Simple validation of Czech company ID (IČ).
Installation
$ composer require lightools/company-id-validator
Simple usage
$validator = new Lightools\CompanyIdValidator\CompanyIdValidator(); $validator->isValidId('27082440'); // true $validator->isValidId('25596641'); // true $validator->isValidId('1859951'); // true (leading zero added, you can disable this function in constructor) $validator->isValidId('12345678'); // false
Further validation
If you want to know if subject with some ID really exists, you can use lightools/ares.
How to run tests
$ vendor/bin/tester tests