PHP code example of mostafazs / php-validator
1. Go to this page and download the library: Download mostafazs/php-validator 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/ */
mostafazs / php-validator example snippets
'aliases' => array(
'App' => 'Illuminate\Support\Facades\App',
...
'View' => 'Illuminate\Support\Facades\View',
'Validator' => 'mostafazs\php-validator',
),
$result = Validator::filledIn($input);
var_dump($result);
$result = Validator::length($input,$operator,$length);
var_dump($result);
$result = Validator::email($email);
var_dump($result);
$result = Validator::compase($einput1,$input2,caseSensitive);
var_dump($result);
$result = Validator::lengthBetween($input,$min,$max,$inclusive);
var_dump($result);
$result = Validator::value($input,$operator,$length);
var_dump($result);
$result = Validator::alpha($input);
var_dump($result);
$result = Validator::alphanumeric($input);
var_dump($result);
$result = Validator::date($date,$format);
var_dump($result);
$result = Validator::Url($input);
var_dump($result);
$result = Validator::Ip($input,$ip_version);
var_dump($result);
json
""mostafazs/php-validator": "1.*"
},