PHP code example of intervention / validation
1. Go to this page and download the library: Download intervention/validation 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/ */
intervention / validation example snippets
use Illuminate\Support\Facades\Validator;
use Intervention\Validation\Rules\Creditcard;
use Intervention\Validation\Rules\Hexadecimalcolor;
use Intervention\Validation\Rules\Username;
$validator = Validator::make($request->all(), [
'color' => new Hexadecimalcolor([3, 6]), // pass rule as object
'number' => ['
// example
'iban' => 'Please enter IBAN number!',