本文介绍了为什么会用codeigniter自动失效?如果网页使用了Ajax科林的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是新来的PHP codeigniter会议。我有我的网站上会话过期一个问题。         我使用AJAX科尔的贴膜advertizing格在我们的网站页面,并添加到购物车功能,以相同的页面上添加多个产品。但是我的购物车产品附加值是空的,由于会议Appro公司后得到过期。 4-5分钟。我已经做了很多的研究这个问题。我想我的网站的会话已过期,由于科林Ajax和更新会话ID在同一time.But我不知道该

I am new comer with php codeigniter session. i have a issue about session expiration on my site. I am using ajax coll for laoding advertizing div on our site page and also add to cart feature to add multiple products on same page. but my cart added products is empty due to session getting expired after appro. 4-5 minutes.I have done lot of study about this issue. i think my site session is expired due to colling ajax and updating session id at same time.But i am not sure for that.

例如我已经配置config.php文件 -

$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration']  = 0;
$config['sess_encrypt_cookie']= FALSE;
$config['sess_use_database']= TRUE;
$config['sess_table_name']  = 'ci_sessions';
$config['sess_match_ip']    = FALSE;
$config['sess_match_useragent']= TRUE;
$config['sess_time_to_update'] = 300;

我也创建表(ci_sessions)。

I have also created table(ci_sessions).

请给我一个解决方案来解决这个问题。

感谢。

推荐答案

有一个补丁session.php文件中的CI去年解决了AJAX +会议的问题过期问题,请看看下面的补丁的

There was a patch for session.php in CI last year that resolved the issue of ajax+session expire problem please the look at the following patch LINK HERE

这篇关于为什么会用codeigniter自动失效?如果网页使用了Ajax科林的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-02 18:20