PHP code example of artisaninweb / laravel-formvalidation-helper

1. Go to this page and download the library: Download artisaninweb/laravel-formvalidation-helper 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/ */

    

artisaninweb / laravel-formvalidation-helper example snippets


Form::text('field-name','field-value',[

// Replace the error with you own.
Form::error('field-name','<p>You can put a custom html error here.</p>');

// Only replace the html tags
Form::error('field-name','<p>:message</p>');

echo Form::open(['url' => '/login']);
echo Form::text('email', '', ['rm::password('password', '', ['rm::close();

Form::validate(function($postData,$passes,$messages) {
    var_dump($postData);
    var_dump($passes);
    var_dump($messages);
});