Can't increase upload_max_filesize in a Wordpress LAMP stack

I've been trying to increase the maximum upload size of my Wordpress instance, and I've already tried all methods mentioned in the results I get when searching this issue.

I've tried changing the php.ini file, the .htaccess, the wp-config.php, etc. and it's still doesn't change from 2MB.

This might be important:
If I run php -i and find the upload_max_filesize, it shows up with the increased value, but when I print a phpinfo();, it displays the default 2MB, even though both display the same path in "Loaded Configuration File".

Do you have any idea on what I'm missing? It's getting very frustrating.
Thanks in advance


So you checked phpinfo() for Loaded Configuration File, made the appropriate changed to memory_limit, post_max_size, and upload_max_filesize, then restarted Apache and... nothing changed.

Try comparing the outputs of:

php -i | grep -E "Loaded Configuration File|memory_limit|post_max_size|upload_max_filesize"

and

lynx -dump (URL of phpinfo.php) | grep -E "Loaded Configuration File|memory_limit|post_max_size|upload_max_filesize"

You may find that phpinfo() and php -i are loading different configuration files, and that you've changed the only one.