czechphp/national-identification-number-validator

Validator for national identification number in the Czech Republic

V1.0.1 2020-08-11 17:36 UTC

This package is auto-updated.

Last update: 2024-09-12 03:28:14 UTC


README

Czech: Validátor rodného čísla

Build Status codecov

Installation

Install the latest version with

$ composer require czechphp/national-identification-number-validator

Basic usage

<?php

use Czechphp\NationalIdentificationNumberValidator\NationalIdentificationNumberValidator;

$validator = new NationalIdentificationNumberValidator();
$violation = $validator->validate('401224/001');

if ($violation === NationalIdentificationNumberValidator::ERROR_NONE) {
    // valid
}