Laravel 4 package for a really basic HTTP authentication process.
-
Install package
In composer.json (of the root of your project) add the package:
{ ... "require": { ... "FR6/lazyauth": "dev-master" }, "repositories": [{ "type": "git", "url": "[email protected]:FR6/lazyauth.git" }], ... }
$ composer update FR6/lazyauth
In app/config/app.php
'providers' => array( ... 'FR6\Lazyauth\LazyauthServiceProvider' )
$ composer dump-autoload
-
Publish configuration file
$ php artisan config:publish fr6/lazyauth
In your routes.php:
Route::group(array('before' => 'lazyauth', 'prefix' => 'admin'), function(){
Route::get('/', function(){
...
});
});