Answer the question
In order to leave comments, you need to log in
How to pass auth to parent?
Goodnight.
Tell me, controller2 is registered in the routing. Controller 2 inherits controller 1 in which I am trying to get Auth id, but for some reason does not want to give it back. Only in controller 2.
Thanks
again Routing
Main controllerRoute::get('/home', 'panel\[email protected]');
class HomeController extends MainPanelController
{
function index() {
}
}
class MainPanelController extends Controller
{
function __construct()
{
echo Auth::id();
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question