Answers for "laravel current route with parameters"

PHP
3

laravel get current route name

Route::currentRouteName()
Posted by: Guest on July-24-2020
5

named route with parameter laravel

Route::get('/menu/{category}/{product}/{item}', ['as' => 'named.route' , 'uses' => 'MenuController@listItem']);

// to get the actual linke
route('named.route', ['category' => $category->id, 'product' => $product->id, 'item' => $item->id]);
Posted by: Guest on May-29-2020
4

laravel get route

Route::get('foo', function () {
    return 'Hello World';
});
Posted by: Guest on March-10-2020

Code answers related to "laravel current route with parameters"

Browse Popular Code Answers by Language