当我上传图片时
出现错误
错误致命错误:允许的 67108864 字节的内存大小已用尽(试图分配 2157 字节) in...
ERROR Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 2157 bytes) in...
为什么会发生这种情况,当 67108864 = 64MB 时?
Why this happen, when 67108864 = 64MB?
我使用共享服务器.我的 .htaccess 是:
I use a shared server. My .htaccess is:
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^$ webroot/ [L]
RewriteRule (.*) webroot/$1 [L]
</IfModule>
我必须在哪里写php_value memory_limit 128M?
看来你只有 64M (67108864/1024/1024) 分配给 PHP.
It seems you only have 64M (67108864 / 1024 / 1024) allocated to PHP.
如果您可以访问 php.ini,请增加最大内存大小.
If you have access to your php.ini, increase the max memory size.
您也可以在引导 PHP 脚本中执行此操作.
You can also do it in a bootstrap PHP script.
ini_set('memory_limit', '128M');
甚至在你的 .htaccess
php_value memory_limit 128M
这篇关于错误:已用完允许的 67108864 字节的内存大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!
不能使用 'Object 作为类名,因为它是保留的Cannot use #39;Object as class name as it is reserved Cake 2.2.x(不能使用 Object 作为类名,因为它是保留的 Cake 2.2.x)
OAuth 重定向后会话丢失Session is lost after an OAuth redirect(OAuth 重定向后会话丢失)
Cakephp 3.x 中的分页排序Pagination Sort in Cakephp 3.x(Cakephp 3.x 中的分页排序)
CakePHP 多个应用程序的共享核心CakePHP Shared core for multiple apps(CakePHP 多个应用程序的共享核心)
在 CakePHP 3 上登录 [ Auth->identify() ] 始终为 falLogin [ Auth-gt;identify() ] always false on CakePHP 3(在 CakePHP 3 上登录 [ Auth-identify() ] 始终为 false)
致命错误:允许的内存大小为 134217728 字节已用尽Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 87 bytes)(致命错误:允许的内存大小为 134217728 字节已用尽