Open areaboy opened 1 year ago
Hi @areaboy. It's a feature, when you request your different lambdas they have different user space. You can imagine them like different docker containers. You need to use some shared space, for example redis, if you need multiple lambdas. Or you can use one lambda (one index.php) and require different session.php
file according routes.
Thanks for getting back to me. Please do you have a php sample code and vercel.json sample configuration. Am New to Vercel. Thanks
I have encouter this issue before but I end up using databse as session driver. just need to provide your db credential and SESSION_DRIVER=database
is fine
How would I go about doing that? I'm very new to php and Vercel so I don't fully understand where to write that. Thank you
@Transyfor the place for me to put db credential and SESSION_DRIVER=database
is file .env
at the root directory
same problem
suggest
'driver' => env('SESSION_DRIVER', 'file'),
replace
'driver' => env('SESSION_DRIVER', 'cookie'),
Here is my vercel.json file
here is my session script api/session1.php
api/session2.php
The session is not working at all