Answers for "IF THERE IS NO ERRORS laravel"

PHP
0

$errors show this error in laravel

<input type="text" name="firstname">
@if($errors->has('firstname'))
    <div class="error">{{ $errors->first('firstname') }}</div>
@endif
Posted by: Guest on November-07-2020
2

laravel get errors from validator blade

<!-- /resources/views/post/create.blade.php -->

<h1>Create Post</h1>

@if ($errors->any())
    <div class="alert alert-danger">
        <ul>
            @foreach ($errors->all() as $error)
                <li>{{ $error }}</li>
            @endforeach
        </ul>
    </div>
@endif

<!-- Create Post Form -->
Posted by: Guest on August-22-2020

Code answers related to "IF THERE IS NO ERRORS laravel"

Browse Popular Code Answers by Language