I'm building an app on my localhost. When I login via one subdomain, (eg sub.localhost/) I need to access that logged-in user with Auth:: in all other subdomains of my application (eg sub2.localhost/, sub3.localhost/).
I made the change as this post suggests in config/session.php:
'domain' => '.localhost/',
No beans. In fact now I can't log in at all. Does this only work with a non-localhost domain? That would suck.
Did you try with only .localhost instead of .localhost/
if it is still doesn't work you can create an other host pointing to 127.0.0.1 : edit the /etc/hosts or Windows\\System32\\drivers\\etc\\hosts to set an other hostname for example : 127.0.0.1 host.loc
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.