When I tried lớn upload a plugin for my Wordpress template in wamp 2.0 I got an error:

The uploaded tệp tin exceeds the upload_max_filesize directive in php.ini

How lớn fix this error?

asked May 1, năm nhâm thìn at 5:05

4

Seeing as though you've mentioned WAMP, I'm going lớn assume you can edit the php.ini file?

If you left click on the WAMP icon in the status bar, select the PHP thực đơn and then click on the php.ini tệp tin in that thực đơn. Just open it in Notepad is fine.

Then in Notepad, tự a tìm kiếm (CTRL+F) for "upload_max_filesize", and then you can change the value that is phối there.

I don't remember what the mặc định is, but for mine, I have it phối lớn "200M" (without the quotes). This means 200mb.

Save the tệp tin, close it, and then restart WAMP.

You should then be right lớn upload your plugin

answered May 1, năm nhâm thìn at 5:20

1

We have seen this error at least once if we have used WordPress.When installing a theme, plugin or uploading an image or tệp tin, It has nothing lớn tự with the theme or plugin. The issue is with our server settings which limit the maximum size for uploaded files.

It’s a common error and it can be easily fixed. This error message is an indication of that the tệp tin you are trying lớn upload is larger kêu ca your trang web host allows (WordPress mặc định tệp tin upload size is 2 MB).

The uploaded tệp tin exceeds the upload_max_filesize directive in php.ini

Solution:

A solution is easy, need lớn increase the tệp tin size upload limit.

If using WordPress on a local machine using XAMPP, we will find the php.ini in the following locations. Windows: C:/xampp/php/php.ini

Open the php.ini tệp tin. Find these lines in the php.ini tệp tin and replace it following numbers

upload_max_filesize = 64M

Save the changes and refresh your trang web and try uploading the tệp tin again. You will now get success.

answered Sep 29, 2018 at 10:21

1

In Wamp > PHP > php.ini tệp tin, put or edit these lines, and then restart your Wamp server.

post_max_size = 750M 
upload_max_filesize = 750M 
max_execution_time = 5000
max_input_time = 5000  
memory_limit = 1000M

Pang

10k146 gold badges85 silver badges124 bronze badges

answered Dec trăng tròn, 2017 at 10:37

A Solution is easy, you just want lớn add plugin in your WordPress.

  1. Download your .zip tệp tin of plugin.
  2. Extract the .zip tệp tin.
  3. Now, upload the extracted thư mục lớn ../wp-content/plugins/ location.
  4. Go lớn the Installed Plugins page in WordPress, Now you can see the plugin is there, which you have recently uploaded.
  5. Finally, click activate links.

answered Nov 30, 2018 at 7:30

This error is because your upload_max_filesize variable in php.ini tệp tin is adjusted lớn 2Mb.. change it lớn 64Mb!! This đoạn phim tutorial will help you fixing your error in 60 seconds!! Hope it helps

answered Jan 7, 2019 at 16:34

Open your xampp software and click on config button in front of apache option and select php.ini option

Next find this code

upload_max_filesize=2M

and replace with this code

upload_max_filesize=64M

Now restart apache and mysql and enjoy it

answered Mar 2, 2019 at 18:06

I use MAMP. To locate the 'php.ini' tệp tin, if you also use MAMP, the way Is as follows:

  1. Go lớn the thư mục location where the MAMP is installed. For example, 'C:\MAMP' Is the thư mục location of MAMP.
  2. Go lớn 'conf' thư mục.
  3. From 'localhost:8888/MAMP', you will get 'phpinfo' links under PHP section. Click on the links and from the directed page, get the version of PHP is installed into your system.
  4. From 'conf' thư mục, go lớn the thư mục with the version of PHP you got in the previous step.
  5. Go lớn that thư mục and you will get the required php.ini tệp tin.
  6. Open that tệp tin in any text editor and update the info: (memory_limit = 64M, upload_max_filesize = 128M, post_max_size = 512M)
  7. Restart MAMP. Then you are good lớn go for uploading big files into your local server.

answered Dec 5, 2017 at 14:11

1

Find this line in the php.ini tệp tin upload_max_filesize = 2M and replace it with a higher value (e.g. upload_max_filesize = 64M)

And restart wamp..!

Osify

2,28526 silver badges42 bronze badges

answered Mar 9, 2017 at 7:38

If you're using WAMP 2 you should update lớn Release 3.2.3.x with the GUI you can phối upload_max_filesize lớn 64MB recommended lớn tự ví follow the instructions.

  1. Click WAMP icon at taskbar
  2. Go lớn PHP
  3. PHP Settings
  4. Find "upload_max_filesize" and select the size

answered Apr 7, 2022 at 22:35

Locate the php.ini tệp tin in your local dir. I use Xampp. =>C:\Xampp. Now find the line where it says

upload_max_filesize = 2M

and change this lớn your desired value.

upload_max_filesize = 56M

Restart all your services and you should be able lớn upload your new files.

answered Apr trăng tròn, 2017 at 23:51

Windows: C:/xampp/htdocs/wordpress_project/.htaccess php_value upload_max_filesize 1000M php_value post_max_size 2000M php_value memory_limit 3000M php_value max_execution_time 180 php_value max_input_time 180 // in over tag of wordpress

answered Jul trăng tròn, 2019 at 23:22

I had this issue in Amazon ec2 instance and I had installed wordpress. I modified upload_max_filesize directive in /etc/php.ini. Then I tried restarting the httpd service, but that did not solve my issue.

Rebooting the Amazon ec2 instance solved the issue for mạ.

For some reason, restarting the httpd service did not make the server pick the new values. Rebooting the ec2 instance did the trick