• Resolved dennisroliff

    (@dennisroliff)


    Hello,

    I am working on my website performance and running the WP Site Health tool. I’ve fixed a bunch of things so far but one in particular am having an issue with. My PHP version is 8.3.7

    I am getting a ‘The setting for?post_max_size?is smaller than?upload_max_filesize‘ error in Site Health Status and can see the issue in Site Health Info—->Server. I don’t know how to remedy this issue. As you can see in the jpeg, the Site Health Info—>Server data indicates ‘upload max filesize’ as 1000M and the ‘post max size’ as 500M and I don’t know how to change these numbers.

    Also, in my Cpanel—>Software—>PHP Selector—>Options there is also an ‘upload max filesize’ indicating 2M and a ‘post max size’ indicating 4M. So this is confusing.

    Can anyone shed some light on this situation?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator James Huff

    (@macmanx)

    First, access your server via SFTP or FTP, or a file manager in your hosting account’s control panel (consult your hosting provider’s documentation for specifics on these).

    Now, you’ll find those set most likely in your php.ini file (consult your hosting provider’s documentation or support for how to find that) or your site’s main .htaccess file (if you can’t find a .htaccess file in your site’s directory, ensure that you have set your SFTP or FTP client to view invisible files).

    Thread Starter dennisroliff

    (@dennisroliff)

    hello @macmanx,

    thanks for the input. i spent several hours and a lot of google searching trying to figure out how to locate my php.ini file. apparently it’s supposed to be in the root directory… wasn’t there and none of the ‘how to locate your php.ini file’ hacks worked.

    here is my current main .htaccess file:

    #<IfModule mod_headers.c>
    #    Header set Access-Control-Allow-Origin "*"
    #</IfModule>
    # Removed the prior lines per MDD Hosting ticket 746681
    
    
    RewriteCond %{HTTPS} off
    RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
    RewriteCond %{REQUEST_URI} !^/\.well-known/acme-challenge/.+$
    RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
    RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
    <IfModule LiteSpeed>
    CacheLookup public on
    </IfModule>
    
    # BEGIN WordPress
    # The directives (lines) between "BEGIN WordPress" and "END WordPress" are
    # dynamically generated, and should only be modified via WordPress filters.
    # Any changes to the directives between these markers will be overwritten.
    
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    
    # END WordPress
    
    # php -- BEGIN cPanel-generated handler, do not edit
    # Set the “alt-php83” package as the default “PHP” programming language.
    
    <IfModule mime_module>
      AddHandler application/x-httpd-alt-php83 .php .php8 .phtml
    </IfModule>
    
    # php -- END cPanel-generated handler, do not edit
    Moderator James Huff

    (@macmanx)

    i spent several hours and a lot of google searching trying to figure out how to locate my php.ini file.

    As mentioned, you’ll need to consult your hosting provider’s documentation or support for specifics on finding your php.ini file.

    That’s because the location and availability can differ significantly depending on your hosting provider’s server configuration.

    And, based on your .htaccess file contents, the modifications you’re looking for are in php.ini.

    Thread Starter dennisroliff

    (@dennisroliff)

    Hello @macmanx ,

    I’ve got it knocked. Talked to my service provider and they indicated that their servers don’t generate php.ini files. In order to make tweaks to PHP functions, as you mentioned, the root level .htaccess file was key.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.