0
In Laravel 5, we can take the current route (I mean the class instance) using the class Illuminate\Http\Request
, through the method route
.
Thus:
public function handle(Request $request)
{
$rota = $request->route();
}
What about Laravel 4? How can I do this?
I need to know at a certain point what current route is being requested.
For example:
App::before(function ($request)
{
$rota = /** Quero descobrir como pegar a rota atual aqui **/
});
But that was already answered, no?
– Wallace Maxters