Support the ongoing development of Laravel.io →
Authentication
Last updated 2 years ago.
0

Auth::attempt accept an associative array with all element you want to check against model defined in auth config file.

You shouldn't override anything.

Auth::attempt(['username'=>'...', 'password'=>'...', 'disabled'=>false])

The only 'special' value in array passed to Auth::attempt is password because it will be automatically hashed, so you must pass it not hashed.

I don't know if disabled is a real field in database or an appended one. And I don't know if Auth::attempt works for appended attributes.

Last updated 9 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.