Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Alison Gianotto:
Demystifying Custom Auth in Laravel 5
Nov 21, 2016 @ 17:49:17

Alison Gianotto (a.k.a. Snipe) has a new post on her site talking about custom authentication in Laravel-based applications including built-in functionality and how you can override it to your needs.

I’m a big fan of Laravel. I use it in most of my personal and professional projects, and for the most part it really does make coding fun for me again. One of the things Laravel tries to do (similar to Rails) is to build in the most repetitive things a developer would have to do, for example a user registration/login/forgotten password system.

[...] In each of my current Laravel apps, auth works just a tiny bit differently. Add to that the fact that a few of them were pulled forward from Laravel version 4.2, and things can get confusing and messy. [...] Laravel makes this really, really easy – they just don’t document how to do it very well.

She starts by mentioning the "fresh" install version of building out the auth pieces (php artisan make:auth) but points out that, if a more "hybrid" system is needed, a bit more work is required. She shows you the routes that are created in the "make:auth" process and how/where you need to modify things to customize it to your system. She illustrates with some of her own changes including code examples.

tagged: laravel tutorial custom authentication framework

Link: http://snipe.net/2016/11/demystifying-custom-auth-in-laravel-5/


Trending Topics: