PHP code example of interficie / laravel-spanishid
1. Go to this page and download the library: Download interficie/laravel-spanishid library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
interficie / laravel-spanishid example snippets
SpanishID::isValidDni('1234foo');
SpanishID::isValidCif('1234foo');
SpanishID::isValidNie('1234foo');
SpanishID::isValidNNSS('1234foo');
$rules = [
'dni_field' => 'dni',
'cif_field' => 'cif',
'nie_field' => 'nie',
'nif_field' => 'nif',
'nnss_field' => 'nnss',
];