Resolving Session Not Saving

Sharing is Caring

Tonight, I’ve encountered a very strange situation where the session data was empty after each page reload. Have you ever had an issue with the session data not being set after a page refresh and the session has been for sure been started using session_start() ?

I modified the php.ini file located on the server for the line containing session.save_path to a temporary directory on the server.

session.save_path = /tmp

After making the change, sessions were now available and working again.

Sharing is Caring

Brian is a programmer and technology leader living in Niagara Falls with more than ten years of development experience. He is passionate about automation, business process re-engineering, and building a better tomorrow.

Brian is a proud father of four: two boys, and two girls and has been happily married to Crystal for more than ten years. From time to time, Brian may post about his faith, his family, and definitely about technology.