PHP Warning: POST Content-Length of 8978294 bytes exceeds the limit of 8388608 bytes in Unknown on line 0(PHP 警告:8978294 字节的 POST 内容长度超过第 0 行未知中 8388608 字节的限制)
问题描述
在我的 XAMPP 本地开发环境中尝试在 WordPress 上上传导入时出现此错误:
I am getting this error when trying to upload an import on WordPress on my XAMPP local dev environment:
警告:8978294 字节的 POST 内容长度超出第 0 行 Unknown 中 8388608 字节的限制
Warning: POST Content-Length of 8978294 bytes exceeds the limit of 8388608 bytes in Unknown on line 0
我将 upload_max_filesize
从 2M
更改为 1000M
,但这似乎没有任何作用.
I changed the upload_max_filesize
from 2M
to 1000M
, but that didn't seem to do anything.
有什么想法吗?
推荐答案
8388608 字节为 8M,PHP 中的默认限制.将 php.ini 中的 post_max_size
更新为更大的值.
8388608 bytes is 8M, the default limit in PHP. Update your post_max_size
in php.ini to a larger value.
upload_max_filesize
设置用户可以上传的最大文件大小,同时post_max_size
设置表单中可以通过 POST 发送的最大数据量.
upload_max_filesize
sets the max file size that a user can upload while
post_max_size
sets the maximum amount of data that can be sent via a POST in a form.
所以你可以将 upload_max_filesize
设置为 1 兆,这意味着用户可以上传的最大单个文件是 1 兆字节,但如果 post_max_size 可以一次上传 5 个
设置为 5.
So you can set upload_max_filesize
to 1 meg, which will mean that the biggest single file a user can upload is 1 megabyte, but they could upload 5 of them at once if the post_max_size
was set to 5.
更改将在服务器重启后生效.
Changes will take effect after a restart of the server.
这篇关于PHP 警告:8978294 字节的 POST 内容长度超过第 0 行未知中 8388608 字节的限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:PHP 警告:8978294 字节的 POST 内容长度超过第 0 行未知中 8388608 字节的限制


基础教程推荐
- 在多维数组中查找最大值 2021-01-01
- 在 PHP 中强制下载文件 - 在 Joomla 框架内 2022-01-01
- XAMPP 服务器不加载 CSS 文件 2022-01-01
- 在 Woocommerce 中根据运输方式和付款方式添加费用 2021-01-01
- 如何在 PHP 中的请求之间持久化对象 2022-01-01
- 超薄框架REST服务两次获得输出 2022-01-01
- 通过 PHP SoapClient 请求发送原始 XML 2021-01-01
- mysqli_insert_id 是否有可能在高流量应用程序中返回 2021-01-01
- WooCommerce 中选定产品类别的自定义产品价格后缀 2021-01-01
- Libpuzzle 索引数百万张图片? 2022-01-01