简体   繁体   English

如何在xampp的Wordpress 4.4中更改文件的最大上传大小

[英]How to change max upload size for files in Wordpress 4.4 at xampp

I wanted to upload a template to wordpress 4.4 which is running on xampp but it says that I only can upload 2MB. 我想将模板上传到xampp上运行的wordpress 4.4,但它说我只能上传2MB。 I've googled the problem and found an information that i need to change the parameter upload_max_filesize=32M in the file php.ini. 我已经搜索了这个问题,并找到了我需要在文件php.ini中更改参数upload_max_filesize=32M的信息。 I doesn't found the file in the Wordpress folder but in the xampp folder I found a file called php.ini with the parameter in it and I changed the parameter but nothing happened. 我没有在Wordpress文件夹中找到该文件,但是在xampp文件夹中找到了一个名为php.ini的文件,其中带有参数,并且更改了该参数,但没有任何反应。

What can I do to increase the max template upload space? 如何增加最大模板上传空间?

Have you tried this already? 你已经尝试过了吗? http://www.wpbeginner.com/wp-tutorials/how-to-increase-the-maximum-file-upload-size-in-wordpress/ It contains plenty of ways to increase the max upload size. http://www.wpbeginner.com/wp-tutorials/how-to-increase-the-maximum-file-upload-size-in-wordpress/它包含许多增加最大上传大小的方法。

Make sure you increase post_max_size and upload_max_filesize , both limits. 确保增加两个限制post_max_sizeupload_max_filesize

So for example in PHP.ini: 因此,例如在PHP.ini中:

upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300

Cause it may take longer to upload those files, you might want to increase max_execution_time as well. 由于上载这些文件可能需要更长的时间,因此您可能还需要增加max_execution_time。 post_max_size is the maximum size for all POST body data. post_max_size是所有POST正文数据的最大大小。 upload_max_filesize is a maximum size only for files that are POSTed. upload_max_filesize是仅用于POST文件的最大大小。 Other types of POST body data are not subject to this limit. 其他类型的POST正文数据不受此限制。 See Brad's answer over here: PHP post_max_size vs upload_max_filesize, what is the difference? 在这里查看Brad的答案: PHP post_max_size与upload_max_filesize的区别是什么?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM