How to get current route name in Laravel 5?By Hardik Savani | April 10, 2016 | | 1765 Viewer | Category : Laravel
Share this post:
Whenever you need to get current route name then you can get using Request or Route facade. I give you two example one for using Route facade and another for Request facade. so you can get route name both way and how you can see both example.
$routeName = Request::route()->getName());
$routeName = Route::getCurrentRoute()->getPath();
- How to resolve - tokenmismatchexception in verifycsrftoken.php Laravel 5 Ajax ?
- Jquery - input tags plugin example using jquery.tagsinput.js plugin
- Jquery - Display a loading gif image before a image loads using Eager ImageLoader plugin
- Laravel 5.2 chat message module using socket.io, redis, express and nodejs from from scratch.
- How to change date format using date filter in AngularJS?
- Laravel 5 - Barcode generator example using milon/barcode package
- Laravel 5 - Authenticate user in NodeJS with socket io using JWT.
- How to create a text file for JSON and file download in Laravel 5?