Pls help me. I have the problem with crashed php session in case header redirect: For example - user get any page: https://example.com/any_pages/some_page/ But I want redirect him to: https://example.com/any_pages/some_page/ I do this by using:
header('Location: https://example.com/any_pages/some_page/', true, '301');
I get cookies just before redirect and it all - ok. But at the very beginning of the receiver file I get cookies and it broken:
$_COOKIE:
Array
(
[language] => language=ru
[currency] => currency=RUB
[PHPSESSID] => PHPSESSID=c8fd0e0d100a5d214ee99f205d6d0ff2
)
in result - session crashed. Of course I can parse cookie and restart session, but it`s not right (may be).
May be you know: How do I save the session (and cookie (in cookie i save product_cart)), correctly?
!This problem does not occur for everyone users! All users who have this happening have userAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36 and some mobile browsers (exmpl: Dalvik/2.1.0 (Linux; U; Android 10; Mi MIX 3 MIUI/V12.0.3.0.QEERUXM))
version Chrome ~79-90 and I can`t repeat this problem in virtual machine ((
Sorry for my english :((
Aucun commentaire:
Enregistrer un commentaire