PHP code example of anper / russian-id-laravel

1. Go to this page and download the library: Download anper/russian-id-laravel 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/ */

    

anper / russian-id-laravel example snippets




use Anper\RussianId\Laravel\Rules\BikRule;
use Anper\RussianId\Laravel\Rules\KsRule;
use Anper\RussianId\Laravel\Rules\RsRule;
use Illuminate\Support\Facades\Validator;

$validator = Validator::make([
    'bik_field'=> '...',
    'ks_field' => '...',
    'rs_field' => '...',
], [
    'bik_field'=> new BikRule(),
    'ks_field' => new KsRule('bik_field'),
    'rs_field' => new RsRule('bik_field'),
]);
 bash
$ php artisan vendor:publish --provider="Anper\RussianId\Laravel\RussianIdServiceProvider"