I\'m working on custom Laravel login implementation. I have returned the error from controller as follows:
$credentials = $request->only(\'email\', \'password
Please try it again:
$credentials = $request->only('email', 'password');
if (Auth::attempt($credentials)) {
// Authentication passed...
return redirect()->intended('surveys');
}else {
return redirect()->back()->withErrors(['email' => 'The Message']);
}
Try this :
<div class="col-md-6">
<input id="email" type="email" class="form-control @if($errors->has('email')) is-invalid @endif " name="email" value="{{ old('email') }}" required autocomplete="email" autofocus>
@if($errors->has('email'))
<div class="error"></div>
<span class="invalid-feedback" role="alert">
<strong>{{ $errors->first('email') }}</strong>
</span>
@endif
</div>