Package Data | |
---|---|
Maintainer Username: | sdavis1902 |
Maintainer Contact: | s.davis1902@gmail.com (Scott Davis) |
Package Create Date: | 2017-02-01 |
Package Last Update: | 2017-08-31 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-19 03:01:39 |
Package Statistics | |
---|---|
Total Downloads: | 3,595 |
Monthly Downloads: | 17 |
Daily Downloads: | 0 |
Total Stars: | 3 |
Total Watchers: | 1 |
Total Forks: | 1 |
Total Open Issues: | 0 |
As of Laravel 5.3, Route::controller was removed. This provides the same functionality.
Via Composer
$ composer require sdavis1902/laravel-controller-routes
Once installed add the service provider and alias ( not required for 5.5 )
'providers' => [
...
sdavis1902\LaravelControllerRoutes\LaravelControllerRoutesServiceProvider::class,
],
'aliases' => [
...
'MoreRoute' => sdavis1902\LaravelControllerRoutes\Facades\MoreRoute::class,
],
In your routes file
MoreRoute::controller('/test', 'TestController');
Your Controller
class TestController extends Controller {
public function getFrank(){
return 'woo';
}
}
You can now go to yourdomain.comm/test/frank and it should say "woo"
Please see CONTRIBUTING and CONDUCT for details.
The MIT License (MIT). Please see License File for more information.