• Daniel

    (@daniel_word_press)


    Hi WP Gurus!

    I’m wondering if there is a code for functions.php that can increase upload size for files once is required by user session. I mean that I need it only when the user requests to upload a file, not in the php.ini or htaccess as general rule (for security issues).

    Example:
    User must upload 1 file of 250 MB or 5 files of 50 MB without having time outs.

    My .htaccess limits are:
    php_value upload_max_filesize 16M
    php_value post_max_size 16M
    php_value max_execution_time 300
    php_value max_input_time 300

    I need some code in functions.php (I’m using Genesis – Child theme) that can increase temporarily this limit on session start of each upload request.

    Thank you for you time!

    Cheers!
    Daniel

Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    You can try something like @ini_set('memory_limit','250M');
    Success is dependent on server configuration, but in theory many php.ini settings can be overridden this way.

Viewing 1 replies (of 1 total)
  • The topic ‘Max execution time for session start’ is closed to new replies.