Route List & Route Controller
laravel code / August 23, 2018
Route List & Route Controller in Laravel
any and match function and artisan laravel command line
Route::any(‘admin’,function(){
});
Route::match([‘put’,’patch’],’admin’,function() {
});
How to command line show how to created route file
(1)php artisan route:list
step 1: controller define in routes
Route::controller(‘admin’,’AdminController@index’);
step 2:Created function created
<?php
namespace AppHttpControllers;
class AdminController extends Controller {
public function index()
{
echo “getDashboard method”;
}
public function getAddUser()
{
echo “Hii”;
}
}
?>