rickard2/luhnar-validator

Symfony 2 validator to validate social security numbers

2.4.2 2024-09-06 09:15 UTC

This package is auto-updated.

Last update: 2024-12-10 13:02:53 UTC


README

Uses my Luhnar package to validate social security numbers in symfony.

PHP Component: https://github.com/rickard2/luhnar

JavaScript Equivalent: https://github.com/rickard2/luhnarjs

Usage example:

use Rickard2\LuhnarValidator\SocialSecurityNumber as SocialSecurityNumber;

class Person {
    /**
     * @ORM\Column(name="socialSecurityNumber", type="string", length=13)
     * @SocialSecurityNumber(countryCode="SE")
     */
    private $ssn;
}