OSX El Capitan local install Maximum upload file size: 2 MB But php.ini set to 64M

Brand new site. Not MU. No matter what I do, I cannot get a file uploaded that exceeds 2MB. I'm running a localhost server with WordPress 4.3.1

I've modified both relevant settings in the the site's php.ini as:

upload_max_filesize = 64M
post_max_size = 64M

However, I'm still getting the message when trying to upload a plugin that's 2.5M

The uploaded file exceeds the upload_max_filesize directive in php.ini.

Also, when I go to "Media > Add New", I get the message:

Maximum upload file size: 2 MB.

My htaccess file is the default and has no mention of max upload size.

What gives? Is it a requirement to restart anything after modifying the site's php.ini? If so, I could not find a restart command on my phpmyadmin panel.

Topic php.ini localhost uploads wp-admin Wordpress

Category Web


The first things to check is PHP.ini file. The values of upload_max_filesize, memory_limit and post_max_size in the php.ini configuration file exactly.

All of these three settings limit the maximum size of data that can be submitted and handled by PHP.

Typically post_max_size and memory_limit need to be larger than upload_max_filesize


Check to see if anything is hooked to the upload_size_limit filter.

This can be a hard one to track down. (I once used a plugin that set it to 1MB for reasons I never figured out. It took a long time to find the issue.)


Most likely, there are two php.ini files, one for the local server and one for the site. You can change the site's upload_max_filesize to whatever you want, if the server's php-settings say it's 2 MB, that's it.

So, find the php.ini file of your server install and change the value. Then reboot.

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.