Getting the route detail by name
Ad
Is it possible to get the details of a route by it's name like the controller and action name that it uses?
I went through the documentation and it only has such functionality listed for the current route i.e. current()
, currentRouteAction()
etc. Is it possible to get the detail of a route, action and controller to be specific, by it's alias/name?
Ad
Answer
Ad
I think, you can get it in this way
Route::getRoutes()->getByName($name);
or
Route::getRoutes()->getByAction($action);
Ad
source: stackoverflow.com
Related Questions
Ad
- → "failed to open stream" error when executing "migrate:make"
- → October CMS Plugin Routes.php not registering
- → OctoberCMS Migrate Table
- → OctoberCMS Rain User plugin not working or redirecting
- → October CMS Custom Mail Layout
- → October CMS - How to correctly route
- → October CMS create a multi select Form field
- → October CMS - Conditionally Load a Different Page
- → How to disable assets combining on development in OctoberCMS
- → October CMS - Radio Button Ajax Click Twice in a Row Causes Content to disappear
- → OctoberCms component: How to display all ID(items) instead of sorting only one ID?
- → In OctoberCMS how do you find the hint path?
- → How to register middlewares in OctoberCMS plugin?
Ad