问题描述
我有一个大表单,我可以从 firebug 看到所有元素的值都被正确发送,但是当我打印_r($_POST) 时,只显示了 1000 个变量.我的 max_post_size 设置为 25M,所以我知道这不是问题,我在 php.ini 中搜索了诸如post"和max"之类的关键字,但没有找到任何内容.
I've got a large form and I can see from firebug that all of the elements' values are being sent properly, but when I print_r($_POST) there are only 1000 variables displayed. My max_post_size is set to 25M so I know that's not the issue and I searched through my php.ini for keywords like 'post' and 'max' and I didn't find anything.
1000 仅是我传递的元素的 1/4 左右,所以显然这对我来说是一个很大的问题,我非常感谢我能得到的任何帮助.
1000 is only about 1/4 of the elements that I'm passing so obviously this is a pretty big issue for me, I really appreciate any help I can get.
推荐答案
我明白你在这里做了什么.
I see what you did here.
max_input_vars, 1000
为了防止哈希碰撞攻击而引入:http://www.phpclasses.org/blog/post/171-PHP-Vulnerability-May-Halt-Millions-of-Servers.html但是在 5.3.9 失败了:http://www.phpclasses.org/blog/post/175-Another-Serious-Security-Bug-on-PHP-539.html所以如果有问题,你应该更新到 5.3.10+.
Introduced in order to prevent hash collision attack:http://www.phpclasses.org/blog/post/171-PHP-Vulnerability-May-Halt-Millions-of-Servers.htmlBut failed in 5.3.9:http://www.phpclasses.org/blog/post/175-Another-Serious-Security-Bug-on-PHP-539.htmlSo you should update to 5.3.10+ if that is problem.
这篇关于php Post 限制为 1000 个变量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!