2017 © Pedro Peláez
 

library luhnar

Validate social security numbers

image

rickard2/luhnar

Validate social security numbers

  • Monday, January 19, 2015
  • by rickard2
  • Repository
  • 2 Watchers
  • 3 Stars
  • 2,514 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 3 Forks
  • 0 Open issues
  • 6 Versions
  • 4 % Grown

The README.md

Luhnar

Validate personnumer (social security numbers), (*1)

Name inspired by the Luhn algorithm used to validate swedish personnummer., (*2)

Usage:, (*3)

$validator = new Rickard2\Luhnar\Validator();

$validator->validate('9909193766', 'se'); // true
$validator->validate('9909193776', 'se'); // false

The swedish validator will accept input in the following formats:, (*4)

  • YYMMDD-NNGC
  • YYMMDD-NNGC
  • YYMMDD+NNGC
  • YYYYMMDDNNGC
  • YYYYMMDD-NNGC
  • YYYYMMDD+NNGC

Source: http://en.wikipedia.org/wiki/National_identification_number#Sweden, (*5)

The finnish validator will accept input in the following formats:, (*6)

  • DDMMYYCZZZQ

Source: http://en.wikipedia.org/wiki/National_identification_number#Finland, (*7)

JavaScript Equivalent: https://github.com/rickard2/luhnarjs, (*8)

Symfony2 validator: https://github.com/rickard2/luhnar-validator, (*9)

The Versions

19/01 2015

dev-master

9999999-dev

Validate social security numbers

  Sources   Download

MIT

by Rickard Andersson

19/01 2015

2.0.0

2.0.0.0

Validate social security numbers

  Sources   Download

MIT

by Rickard Andersson

18/04 2014

1.0.3

1.0.3.0

Validate social security numbers

  Sources   Download

MIT

by Rickard Andersson

01/10 2013

1.0.2

1.0.2.0

Validate social security numbers

  Sources   Download

MIT

by Rickard Andersson

21/08 2013

1.0.1

1.0.1.0

Validate social security numbers

  Sources   Download

MIT

by Rickard Andersson

05/08 2013

1.0.0

1.0.0.0

Validate social security numbers

  Sources   Download

MIT

by Rickard Andersson