Feb 6, 2017
0
Level 1
Maintaining Session After Redirecting to Subdomains
Laravel has a route we can use for subdomains but if we use that method to redirect a user to the subdomain, the session no longer exists.
If we dd Auth::user() we get a blank output and a new cookie is created for that subdomain.
I tried clearing cookies in the browser and in framework/storage/session and config/session.php. I also set the domain='.example.com' but that does't seem to work. The session still breaks after redirection.
I need a method so that I can maintain a continuous session with subdomains even after the redirect. What's the best way to achieve this?
Please or to participate in this conversation.