修改php的memory限制
文章作者:Slyar 文章来源:Slyar Home (www.slyar.com) 转载请注明,谢谢合作。
Xampp搭环境,用xml导入的时候出了点问题,可能很多人也有这样的问题吧,以前我没碰到,今天遇到了。。。
Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 334230 bytes) in D:\xampp\htdocs\test.php on line56
php内存溢出了,无语。来吧,我们修改一下。
1、打开 \xampp\apache\bin\php.ini 。不要去php文件夹找那个php5.ini ,那个不是配置文件。
2、搜索 "memory" 找到以下内容:
;;;;;;;;;;;;;;;;;;;
; Resource Limits ;
;;;;;;;;;;;;;;;;;;;max_execution_time = 60 ; Maximum execution time of each script, in seconds
max_input_time = 60 ; Maximum amount of time each script may spend parsing request data
memory_limit = 32M ; Maximum amount of memory a script may consume (16MB)
3、修改 "memory_limit =" 的值即可,一般改成64M就差不多了。
4、重启Apache ,完毕。
您可能还对以下内容感兴趣
收藏、分享这篇文章! 用 RSS feed 订阅本博客 什么是订阅? Trackback评论
1 条评论 关于 “修改php的memory限制”
发表您的评论[审核后显示]












还没遇到这种情况,不过以后出现了就知道怎么弄了