dimanche 22 mars 2020

How to check for validation error in laravel

I want to check if any error accrue while validating data in laravel

code:

$user = $request->validate([
            'name' => 'required',
            'email' => 'required | email',
            'password' => 'required'
        ]);

any one know how to do that ? I've try to check

if ($user) 

but that does not seems to work !!



from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/33GRQmO
via IFTTT

Aucun commentaire:

Enregistrer un commentaire