![]() |
(08-22-2023, 08:10 AM)ozornick Wrote: Session init in files? See session_cache_limiter() Turn off Yes you're totally right ! Thank you very much for your hint ![]() It led me to the solution I found. I'll develop it in my answer to Kenjis (08-22-2023, 01:48 PM)kenjis Wrote: It is already reported: Sorry, I didn't check for the issues before posting my message. I think I found the origin of the problem thanks to ozornick and a solution (that I implemented already, it works). When using sessions (when the session starts), PHP automatically sends Cache-Control instruction to the header (see my initial post). It implicitely execute this instruction: PHP Code: session_cache_limiter('nocache'); The problem is that the headers sent by session_cache_limiter() cannot be replaced or removed by CodeIgniter methods and functions such as: PHP Code: // removeHeader() does NOT remove the headers sent by session_cache_limiter() The solution is to stop theses headers from being issued BEFORE the session starts by using `session_cache_limiter('');`: PHP Code: // We prevent PHP from sending the cache related headers That's it. It's not really a bug of CodeIgniter, simply (for my part) the ignorance that when starting a session, PHP would send Cache related headers. Thanks for your help. |
Welcome Guest, Not a member yet? Register Sign In |