This is probably the most comprehensive playlist on multiple user authentication in Laravel using the best practices in web development! Thank you for making it happen!
I'm willing to bet that you have the best tutorials on ............any platform really, not just RUclips. Your in-depth approach has helped me understand so much, Thank you man, you're a Super Hero
7 лет назад+78
You are the best my man! Your videos they will be 5-10 min but you explain everything like a teacher and I learded lots of think from you. Best regards from Turkey 👍
Give this guy a medal, what an explanation!!! Laravel docs just make me wanna puke but this is so simple God Bless You buddy don't ever let anything stop you.
Thank you very much for the way you teach us. I do not know if you're a teacher at "real life", but of course you have the capabilities to be without doubt...Congrats from Spain!
After having a hard time trying to find a good tutorial about multi-auth on Laravel, I finally came upon your videos, and it was exactly what I was looking for. Outstanding tutorial, and great explanations!! Thank you so much! Best regards from Brazil!
We are waiting ecommerce video from you. Lots of people start ecommerce video and then they stop after few videos. There is a huge potential about ecommerce system. Btw This series looks amazing.. If you consider ecommerce system for future project. It will be great! thanks
Hi Alex! I am trying to build the Blog project now but as the latest laravel version is 5,4, I thought it would be better to try this video. It is just great. Thank you very much for your engagement! Greetings from Cuba/Sweden.
OMFG finally a good tutorial and with the latest version, i've been going crazy trying to figure it out how the guards and middleware should be linked properly. Subbed, liked and all that good stuff, keep it up man thx a lot.
You know what... I've been looking for this information for quite a while because I wanted to make a multi auth for my own learning project and you showed it well with a example...I really love to learn from you further about laravel... Just a little request from my side is that could you please make a series for new laravel 5.7 auth customization. Cuz a lot of things have changed and I don't wanna follow up my study with old techniques. So pls consider making a dedicated series for that and whole new laravel 5.7 if you can. I'm also a RUclipsr and I would be really happy to get that knowledge from you. Seeing forward . Thanks!!😄😄
Hey there!! Loved your videos and it really is helpful. Thanks for you time and effort. However, I want to ask you if this is applicable for Laravel 5.8??
Well, First of all I have to say thank you to share your knowledge. Your videos was very helpful for me and these are great. I want to ask you to please create a video-cast about laravel core and teach us how the Laravel core really work. for example when user visits index.php, what classes will load and how Laravel structure works together. I start learning laravel recently and watched all your videos about new feathers in laravel 5.4 but as I'm a newbie, I always code in laravel with fear because I'm afraid that changing something may be damage my code and debugging may get more time. Sorry for my poor English grammar and I hope I could tell my opinion
Alex, you might want to look into your video quality settings; It's fine, but it's not right for 1080p. It's blurry and your webcam in this video looks like it's frame blending a low framerate...
Great video 👍 !! thanks a lot man, made a huge difference in my understanding.. what if i have already migrated the users table? can i now create the admin table and then migrate it ???
Hey this is really cool!!! do have anything done for LDAP, I am using adldap2 that works fine, I would like to know how Laravel handles or knows what user is logged and how to work with that. Thanks!
Hi, there is a slight modification in the Exception handler you used in the redirect if not authenticated in laravel 5.5. Can you please review. You have been a great teacher and help to me which i wholeheartedly appreciate
Awesome man! I already know about authentication but this make some much clear... actually I already have a separation with namespaces between my website logic and admin / cms logic but I wasn't sure if this was the right way to do it. So thanks for your time on this videos!
Interesting tutorial, but I'm waiting for your "Build Advanced Blog/ CMS from Start to Finish" series, Please give priority to that series, becoz you may agree with me that, that series will teach us lot more than any series here created yet. So please.
JaCurtis your tutorials are helpful and amazing, Please can your do a short series on how to use cron jobs in laravel. i have searched i have not really found a very useful tutorial on cron jobs. thank you.
Hi Brother, I have a customer who has 4 shops to manage his inventory system what is your best suggestion for me. it is better to have a company_id in each table or go for multi database tenanti?
I would either use a company_id or location_id and a seperate table for company/location. The for the location model have a function public parts() { return $this->hasMany(Parts::class) } and then in the parts do a public function location { return $this->belongsTo(Location::class) } you can lookup all parts parts::all or parts::where('location_id', location_id)
Hi! thanks my friend, the tutorial is very well done. All the steps were clear and easy to understand. Thanks a lot for the video and please don't stop making good stuff like this!
Hello Elon. Thanks for the video tutorials. I am working on a db and revenue auto system. Pls, could you guide me on the best bundle to make the job easier or possibly the best approach. Tanks. Regards.
Wonderful video - if you joined Laracasts, I would consider getting a subscription. I love Jeffrey, but you are my go-to for Laravel stuff. Great content, and your delivery is fantastic. Thanks for being attentive to your viewers' requests, you're an awesome dude.
Never seen guards used this way. In my apps, I would generally keep all users under one table, but then distinguish them based on roles or abilities (I used Bouncer package to handle that for me :). Because customers need more data stored, I'd just create a dedicated customers table with user_id and have a belongsTo/hasOne relationship. I do like your approach, though I dislike that shared state (email, password, remember token, etc.) are duplicated across two tables. But as long as user-bound things like notifications or Stripe-related functionality if using Cashier are working just fine for both User and Admin models, I guess you could use both? Not sure if Admin is fully compatible with User though...
notifications and payments tables are usually separate or if its subscription based the table would also be separate. then you could lookup user::with('payments') or notifications, or profile fields, etc. I like the idea, but i think its easier to create a route middleware with isAdmin and a field in the table isAdmin.
Hi, thanks for the tutorials I have a question though Isn't it better to have one table for User which have all the common columns of users and have a column of (user_type =enum('admin' , 'customer' , 'company' ) etc... , and then have a foreign key for each table (user_id) which will point to the id in user id and if you have lots of different fields for each user type , you could use table for each with those different fields ? i would have put them in one Table and call it a day with putting all the different fields as nullable , but at the end I would need a different underlying business logic for my different type of users , so I would build a Model and a Controller for each one , so that's why I made a table also for each user type , with fields different from each other user (and I use foreign key user_id) Q1 : Is this method better and more readable? Q2: If we are using this method , would we need to have more than guard ? Thank you again and best Regards from Egypt :)
Thank you sir for this tutorials, l had understood multiple authentication well, my question is how do l use the same login form to direct to mutiple users dashbords. thanks following you in Zimbabwe
Hi Alex, i haver some problem here. How to implement AuthServiceProvider for this admin guard ? so, I just wanna make role in admin tables, and in the AuthServiceProvider will add some gate define like this: Gate::define('admin-access', function ($admin) { return $admin->role == 'admin'; }); Gate::define('manager-access', function ($admin) { return $admin->role == 'manager'; }); Gate::define('supervisor-access', function ($admin) { return $admin->role == 'supervisor'; }); And I create a middleware with this function: public function handle($request, Closure $next, $role) { if (Auth::guard('admin')->can($role, '-access')) { return $next($request); } return response('Unauthorized', 401); } How can I use this roles with middleware like. role:admin or role:supervisor?
Hi DevMarketer! Another question, can you assign both auth and auth:admin to a controller? I have made a controller which both a user and an admin can use to avoid double code.
Hey! Alex, thanks for the great content, its been always inspiring to implement the learnings into reality and that's why I have been following your content and It helped me a lot.
So Alex currently I am developing an application where I wanted to have separate admin portion on some subdomain and rest application on main domain. Actually I wanted to have different types of users at different subdomain. And I got stuck into it and unable to figure it out. Can you help me out on this. Thank you in advance and I am waiting for your positive response.
Hello , I love your videos , I juste have one question if you may , can we use all that without making the make:auth commande ? Like i know how to register and login , can i use the middlware without using that commande , thank u
Cool bro... can you also post a new video that will allow admin to see the list of web-users and a button against each web user (password is saved in db in encrypted format ...bcrypt) for admin to login as a web-user?
Dude, even my dog understood your video! Thank you for your teaching.
This is probably the most comprehensive playlist on multiple user authentication in Laravel using the best practices in web development! Thank you for making it happen!
I signed in to thank you specifically. You are the part that makes me graduate.I wish you success in everything.Thank You,so luck
I'm willing to bet that you have the best tutorials on ............any platform really, not just RUclips. Your in-depth approach has helped me understand so much, Thank you man, you're a Super Hero
You are the best my man! Your videos they will be 5-10 min but you explain everything like a teacher and I learded lots of think from you.
Best regards from Turkey 👍
mee too
Bro!! this is fake channel making money by fake channel this is udemy course video downloaded and then make 1 and making money
Don't be stupid, if it were an Udemy Course he wouldn't say "I didn't know how to do it"
Still helpful in 2021 with Laravel 8.x :D
Give this guy a medal, what an explanation!!! Laravel docs just make me wanna puke but this is so simple God Bless You buddy don't ever let anything stop you.
Your tutorials are amazing. I have followed you using laravel version 7.0.8 and Multiple Authentication have worked perfectly.
The only available and best tutorial, which explained Multi Auth in details. Really impressed by your work. Thums Up:
Thank you very much for the way you teach us. I do not know if you're a teacher at
"real life", but of course you have the capabilities to be without doubt...Congrats from Spain!
After having a hard time trying to find a good tutorial about multi-auth on Laravel, I finally came upon your videos, and it was exactly what I was looking for. Outstanding tutorial, and great explanations!! Thank you so much! Best regards from Brazil!
Wooow man I have watched a lot of tutorials on multi auth but this is by far the best of all. it works like magic.
Do You know that you are the first guy who explain this perfectly ? Amazing job man!
I really like that you are doing more advanced tutorials!
your tutorials are so good! :)
We are waiting ecommerce video from you. Lots of people start ecommerce video and then they stop after few videos. There is a huge potential about ecommerce system. Btw This series looks amazing.. If you consider ecommerce system for future project. It will be great! thanks
Hi Alex!
I am trying to build the Blog project now but as the latest laravel version is 5,4, I thought it would be better to try this video. It is just great. Thank you very much for your engagement! Greetings from Cuba/Sweden.
Oh my God i spent a lot of time searching you are the only one that explain it the right way. thank you
OMFG finally a good tutorial and with the latest version, i've been going crazy trying to figure it out how the guards and middleware should be linked properly. Subbed, liked and all that good stuff, keep it up man thx a lot.
Thanks Alex, You are doing great. Assume the people viewing your videos are introverts and shy enough to thumb up. Please keep it up regardless o'that
You know what... I've been looking for this information for quite a while because I wanted to make a multi auth for my own learning project and you showed it well with a example...I really love to learn from you further about laravel...
Just a little request from my side is that could you please make a series for new laravel 5.7 auth customization. Cuz a lot of things have changed and I don't wanna follow up my study with old techniques.
So pls consider making a dedicated series for that and whole new laravel 5.7 if you can.
I'm also a RUclipsr and I would be really happy to get that knowledge from you.
Seeing forward . Thanks!!😄😄
Loved your Laravel eLearning course. Hope you make a new eLearning course for newer versions, too.
maan you killin it. you explain laravel authentication like a pro. Thank you it really save my time!
Hey there!! Loved your videos and it really is helpful. Thanks for you time and effort. However, I want to ask you if this is applicable for Laravel 5.8??
yes
Well, First of all I have to say thank you to share your knowledge.
Your videos was very helpful for me and these are great.
I want to ask you to please create a video-cast about laravel core and teach us how the Laravel core really work.
for example when user visits index.php, what classes will load and how Laravel structure works together.
I start learning laravel recently and watched all your videos about new feathers in laravel 5.4 but as I'm a newbie, I always code in laravel with fear because I'm afraid that changing something may be damage my code and debugging may get more time.
Sorry for my poor English grammar and I hope I could tell my opinion
finally got the native multi auth hoooraaaay!! been waiting for this for tooooooooo long.. God bless u bro!
It's 2020 and you saved my life...
I love your videos Elon, I don't know how you manage to get time to make laravel tutorials while building tesla
does he work for tesla ?
lol you didn't get it !
Luis Alberto Guerra Luis ok I get it now ! :D
Lol this cracked me up 😂
I laughed way too hard at this
Great tutorial .....saving lives of many developer ....keep it up
very straight-forward, simple, native, easy to digest.. many thanks bro!
Thanks Dude. I'm almost frustated learn auth Laravel. But you explain it easily ....
Great videos! I was wondering if laravel can set different sessions per user type?
Alex, you might want to look into your video quality settings; It's fine, but it's not right for 1080p. It's blurry and your webcam in this video looks like it's frame blending a low framerate...
Great video 👍 !!
thanks a lot man, made a huge difference in my understanding..
what if i have already migrated the users table?
can i now create the admin table and then migrate it ???
You teaching video is very clean and clear! Very helpful! Thank you!
this is one of the greatest tutorials i've ever seen ! thank you elon ! keep going
Came here again just to give you a thumb up. Many thanks for this tutorial. You are awesome tutor.
Hey this is really cool!!! do have anything done for LDAP, I am using adldap2 that works fine, I would like to know how Laravel handles or knows what user is logged and how to work with that. Thanks!
this is the best ACL video with laravel on youtube! thanks man!!
Dude you are awesome, just when I was giving up on learning Laravel I found your channel! Thanks.
100 likes... LOVE UR EFFORTS MAN. GREAT AND CLEAN AND CLEAR DELIVERY...
Hi, there is a slight modification in the Exception handler you used in the redirect if not authenticated in laravel 5.5. Can you please review. You have been a great teacher and help to me which i wholeheartedly appreciate
Awesome man! I already know about authentication but this make some much clear... actually I already have a separation with namespaces between my website logic and admin / cms logic but I wasn't sure if this was the right way to do it. So thanks for your time on this videos!
Very clean and cool video for laravel developers.
your video was very good Explanation! i am new to laravel do you have an video about GATE laravel?
Interesting tutorial, but I'm waiting for your "Build Advanced Blog/ CMS from Start to Finish" series, Please give priority to that series, becoz you may agree with me that, that series will teach us lot more than any series here created yet. So please.
Was watching for exactly this tutorial... very well explained and very informative... thanks a lot man
started watching the video, immediately pressed Like not to forget to do it later
Hello,
at first thank you for such kind of tutorials.
you are amazing.
can you please tell me, is it going to work on 5.2 ??
Alex, I've been looking for this tutorial for a long time. you're the best. Thank you for the teaching you give me, regards.
Thank you for your great tutorials. Could you tell me what your code editor is?
It's Atom, atom.io/
To the point, and informative. The Best video after searching a lot. Thank you very much for sharing the information.
Exactly what i've been looking for. Thank you Curtis
Your video is really good, nice and clear, easy to follow. Thank you
JaCurtis your tutorials are helpful and amazing, Please can your do a short series on how to use cron jobs in laravel. i have searched i have not really found a very useful tutorial on cron jobs. thank you.
Hi Brother, I have a customer who has 4 shops to manage his inventory system what is your best suggestion for me. it is better to have a company_id in each table or go for multi database tenanti?
I would either use a company_id or location_id and a seperate table for company/location. The for the location model have a function public parts() { return $this->hasMany(Parts::class) } and then in the parts do a public function location { return $this->belongsTo(Location::class) } you can lookup all parts parts::all or parts::where('location_id', location_id)
Thank you Elon
At last I understand multiple authentication. You make it very easy .thank you so much.
Great work! Thanks for that
how u use multi.dev url? its a artisan command?
Yeah i am using Laravel valet.
Hi! thanks my friend, the tutorial is very well done. All the steps were clear and easy to understand. Thanks a lot for the video and please don't stop making good stuff like this!
Hello Elon. Thanks for the video tutorials. I am working on a db and revenue auto system. Pls, could you guide me on the best bundle to make the job easier or possibly the best approach. Tanks. Regards.
You're the best, you're tutorials are saving my life :D i really do enjoy, great explanations keep on ^^
Overwhelmed by this video. So many thanks 🙏🙏🙏
Огромное спасибо!Самые лучшие уроки по Ларавель
An excellent series on this subject. Thank you very much.
Wonderful video - if you joined Laracasts, I would consider getting a subscription. I love Jeffrey, but you are my go-to for Laravel stuff. Great content, and your delivery is fantastic. Thanks for being attentive to your viewers' requests, you're an awesome dude.
Awesome video. Great teacher. Useful content. Thanks a lot
Never seen guards used this way. In my apps, I would generally keep all users under one table, but then distinguish them based on roles or abilities (I used Bouncer package to handle that for me :). Because customers need more data stored, I'd just create a dedicated customers table with user_id and have a belongsTo/hasOne relationship. I do like your approach, though I dislike that shared state (email, password, remember token, etc.) are duplicated across two tables. But as long as user-bound things like notifications or Stripe-related functionality if using Cashier are working just fine for both User and Admin models, I guess you could use both? Not sure if Admin is fully compatible with User though...
notifications and payments tables are usually separate or if its subscription based the table would also be separate. then you could lookup user::with('payments') or notifications, or profile fields, etc. I like the idea, but i think its easier to create a route middleware with isAdmin and a field in the table isAdmin.
Hi, thanks for the tutorials
I have a question though
Isn't it better to have one table for User which have all the common columns of users and have a column of (user_type =enum('admin' , 'customer' , 'company' ) etc... , and then have a foreign key for each table (user_id) which will point to the id in user id
and if you have lots of different fields for each user type , you could use table for each with those different fields ?
i would have put them in one Table and call it a day with putting all the different fields as nullable , but at the end I would need a different underlying business logic for my different type of users , so I would build a Model and a Controller for each one , so that's why I made a table also for each user type , with fields different from each other user (and I use foreign key user_id)
Q1 : Is this method better and more readable?
Q2: If we are using this method , would we need to have more than guard ?
Thank you again and best Regards from Egypt :)
i use this method but in current company i work on it i need video way this amazing to know more than a way to solve your problem ...
Thanks!, I have a question... why you are not using the LoginController that comes in the Auth directory? Is it better this way?
GREAT JOB! Please continue to publish videos
Thank you sir for this tutorials, l had understood multiple authentication well, my question is how do l use the same login form to direct to mutiple users dashbords. thanks following you in Zimbabwe
Your tutorial is very amazing, very explanatory
This is the video i have been looking for long time. Thanks a lot.
im from argentina and can tell u the explication is fantastic, everything works correctly, thanks a lot.
Thank you a million times for the video. I couldn't understand a thing from the Laravel documentation but you just saved me from it.
Hi Alex, can you provide tutorial for Roles Management for Multi Auth.Thanks.
bro! I have learned more with you than the university, thanks a lot... sorry about my bad English :D
I found the colored icons very nice, so i installed that Atom package, thank you!
Great!!!!
And Can you please tell us how to the multi auth in laravel 5.1 ?
Hi Alex, i haver some problem here.
How to implement AuthServiceProvider for this admin guard ?
so, I just wanna make role in admin tables, and in the AuthServiceProvider will add some gate define like this:
Gate::define('admin-access', function ($admin) {
return $admin->role == 'admin';
});
Gate::define('manager-access', function ($admin) {
return $admin->role == 'manager';
});
Gate::define('supervisor-access', function ($admin) {
return $admin->role == 'supervisor';
});
And I create a middleware with this function:
public function handle($request, Closure $next, $role)
{
if (Auth::guard('admin')->can($role, '-access')) {
return $next($request);
}
return response('Unauthorized', 401);
}
How can I use this roles with middleware like. role:admin or role:supervisor?
Hi DevMarketer! Another question, can you assign both auth and auth:admin to a controller? I have made a controller which both a user and an admin can use to avoid double code.
Hey! Alex, thanks for the great content, its been always inspiring to implement the learnings into reality and that's why I have been following your content and It helped me a lot.
So Alex currently I am developing an application where I wanted to have separate admin portion on some subdomain and rest application on main domain. Actually I wanted to have different types of users at different subdomain. And I got stuck into it and unable to figure it out. Can you help me out on this. Thank you in advance and I am waiting for your positive response.
Any reason as to why you stopped creating content? Your work is great I would love to see more!!!!
Thank you for the video. Are you planning to publish "Forgot My Password Functionality across Multiple User Types" tutorial?
laravel has illuminated the artisan in me =)
I like it a lot :)
Just love your videos!
Can you do in the future do the same thing but through API ???
you are a great code instructor!!!!
Hello , I love your videos , I juste have one question if you may , can we use all that without making the make:auth commande ? Like i know how to register and login , can i use the middlware without using that commande , thank u
why wouldnt you use it? It saves time
Thank you very much, i'm new to Laravel, i used to wrote php from scratch, this really helped
Please, can you do a tutorial on token authentication for api, with use-cases ?
Thanks, your video actually privided some light on things that I needed to enquire.
Don't skipped an ads for this guy, so he got paid from his monetize RUclips ads. :)
The same tutorial with laravel 8?
hello what change need to upgrade to 5.8 thanks
i followed the video the same way as he showed with 5.8..and at this point i didnt have face any problem
Cool bro... can you also post a new video that will allow admin to see the list of web-users and a button against each web user (password is saved in db in encrypted format ...bcrypt) for admin to login as a web-user?
Alex, it would be mega cool if you could make a video how to create the same multiauth using laravel passport (OAuth2).
You're amazing! Your video saved my life today!
men this is great, laravel is so perfect and you teach very good :)
What an incredible video brow! Thank you! :)
Thank you. Best tutorial video i have ever seen.
U R THE BEST INSTRUCTOR