Get last part of current URL in Laravel 5 using Blade
Of course there is always the Laravel way:
request()->segment(count(request()->segments()))
You can use Laravel's helper function last
. Like so:
last(request()->segments())
Of course there is always the Laravel way:
request()->segment(count(request()->segments()))
You can use Laravel's helper function last
. Like so:
last(request()->segments())