• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space

The maximum upload value automatically changes to 2MB

1200

Chevereto Member
2MBWWW.PNG
The maximum upload I set in the dashboard-image upload is 32MB, and the tourist upload is 16MB, but every time I visit the site homepage, I find that the maximum upload becomes 2MB.

This phenomenon has occurred many times, I am very puzzled, and I do not think anyone knows the administrator password.
 
The system fixes the not usable max size setting:

PHP:
    // Fix upload_max_filesize_mb if needed
    $ini_upload_max_filesize = G\get_ini_bytes(ini_get('upload_max_filesize'));
    $ini_post_max_size = ini_get('post_max_size') == 0 ? $ini_upload_max_filesize : G\get_ini_bytes(ini_get('post_max_size'));

    Settings::setValue('true_upload_max_filesize', min($ini_upload_max_filesize, $ini_post_max_size));

    if (Settings::get('true_upload_max_filesize') < G\get_bytes(Settings::get('upload_max_filesize_mb') . 'MB')) {
        Settings::update([
            'upload_max_filesize_mb' => G\bytes_to_mb(Settings::get('true_upload_max_filesize')),
        ]);
    }
To allow uploads of 32MB, you need to alter: ini post_max_size, ini upload_max_filesize. The system does this check because uploads will fail if both settings are below your configured value.

In case you missed the docs: https://chevereto.com/docs/requirements
Code:
upload_max_filesize = 20M;
post_max_size = 20M;
max_execution_time = 30;
memory_limit = 512M;
 
The system fixes the not usable max size setting:

PHP:
    // Fix upload_max_filesize_mb if needed
    $ini_upload_max_filesize = G\get_ini_bytes(ini_get('upload_max_filesize'));
    $ini_post_max_size = ini_get('post_max_size') == 0 ? $ini_upload_max_filesize : G\get_ini_bytes(ini_get('post_max_size'));

    Settings::setValue('true_upload_max_filesize', min($ini_upload_max_filesize, $ini_post_max_size));

    if (Settings::get('true_upload_max_filesize') < G\get_bytes(Settings::get('upload_max_filesize_mb') . 'MB')) {
        Settings::update([
            'upload_max_filesize_mb' => G\bytes_to_mb(Settings::get('true_upload_max_filesize')),
        ]);
    }
To allow uploads of 32MB, you need to alter: ini post_max_size, ini upload_max_filesize. The system does this check because uploads will fail if both settings are below your configured value.

In case you missed the docs: https://chevereto.com/docs/requirements
Code:
upload_max_filesize = 20M;
post_max_size = 20M;
max_execution_time = 30;
memory_limit = 512M;

I use the virtual host of the Plesk control panel, and I see on the Plesk control panel that these configurations are larger than 32MB.

512MBupda.PNG
And the maximum upload of ini files displayed on the Chevereto dashboard is greater than 32MB.
 
Back
Top