2
我安裝在我的CakePHP會話超時會很長,由於業務需要,我將其配置在core.php中是這樣的:會話超時差異
Configure::write('Session', array(
'defaults' => 'php',
'timeout' => 4320, //minutes
'cookieTimeout' => 1440, // The session cookie will live for at most 24 hours, this does not effect session timeouts
'checkAgent' => false,
'autoRegenerate' => true, // causes the session expiration time to reset on each page load
'ini' => array(
'session.gc_maxlifetime' => 259200 // 3 day seconds
)
));
我使本地服務器上,並在生產服務器一些測試,我看到一些不同之處:
本地開發環境(PC)
1小時:全成(會話未閉)
2小時:全成(會話未閉)
4小時:succesfull(會話未閉)
生產服務器
1小時:全成(會話未閉)
2小時:不成功(會話關閉)
我需要能夠在pr上有大的超時(最少4個小時) oduction服務器,爲什麼我有本地PC和服務器之間的區別?
我遇到同樣的問題。你有沒有找到解決方案呢? – Leah
還沒有,仍然在尋找解決方案。 – Vito
哦,我明白了。我現在也一直在嘗試不同的事情,現在也不好。如果您找到任何解決方案,請讓我知道。我會讓你知道的。謝謝! – Leah