我如何使用wordpress在CPanel中增加Max_file_upload_size [英] How can i Increase Max_file_upload_size in CPanel using wordpress

查看:75
本文介绍了我如何使用wordpress在CPanel中增加Max_file_upload_size的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用VPS托管,因为我具有CPanel登录详细信息,已安装了wordpress,并且正在尝试导入从上一个网站导出的一些帖子。但是我遇到了类似Max_file_Upload_size超过2M的错误。我更改了最大文件上传大小。
我试图将php.ini文件添加到我的根文件夹中,但是我没有任何改变,也将php.ini也添加到wp-admin文件夹中,但是我无法导入文件。我的Cpanel我没有找到任何php.ini文件。我也在google中尝试,但是我没有得到帮助的答案……。

I am using VPS hosting in that i have CPanel login details ,i was installed wordpress and i am trying import some posts that i have exported from last website.But i am getting the error like Max_file_Upload_size is more than 2M.How can i change the max file upload size . I was try to add php.ini file to my root folder but i didn't get any change and aslo add php.ini into wp-admin folder also,but i didn't able to import the files.In my Cpanel i didn't find any php.ini files.i am trying in google also but i didn't get answer for me help me....

推荐答案

您应该尝试将其添加到 wp-config.php 文件的第二行

You should just try adding this to the 2nd line of your wp-config.php file.

此行处理您的上传最大文件大小 * *您的 php内存。

This line handles your upload max filesize size *and* your php memory.

// this will change your max file size upload AND your php memory
define( 'WP_MEMORY_LIMIT', '64M' );

有关此代码的更多信息,请参见WP Codex(页面下2/3) :

More info can be seen here regarding this code from the WP Codex (2/3 down the page):

WP内存限制-WP Codex

这篇关于我如何使用wordpress在CPanel中增加Max_file_upload_size的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆