我尝试通过编辑config/config.php
中的值来重命名CodeIgniter CSRF Cookie:
$config['csrf_protection'] = TRUE;
$config['csrf_token_name'] = 'mysite_csrf';
$config['csrf_cookie_name'] = 'mysite_csrf';
$config['csrf_expire'] = 7200;
但是当我访问该网站时,Cookie仍显示为:ci_csrf_token
。
为什么会发生这种情况?
答案 0 :(得分:0)
您使用的是哪个版本的CI? 2.0.x中出现错误
https://bitbucket.org/ellislab/codeigniter-reactor/issue/199