Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Upload max size in PHP?

Tags:

php

ini

uploading

Is it possible for the upload of ~100 MB files using PHP?

If so, what changes need to occur in the configuration file (php.ini)?

Sri

like image 215
sri Avatar asked Jul 16 '10 09:07

sri


2 Answers

The following options are relevant:

  • PHP: upload_max_filesize (in php.ini or .htaccess only, won't work using ini_set())
  • PHP: post_max_size (ditto)
  • PHP: max_input_time (ditto, thanks @Thorstein, forgot this one)

and possibly

  • Apache: LimitRequestBody
like image 179
Pekka Avatar answered Sep 28 '22 02:09

Pekka


In your php.ini adjust the value of:

file_uploads = On
upload_max_filesize = 100M //needs to be in {x}M format

And allow larger post size:

post_max_size = 100M
like image 41
miku Avatar answered Sep 28 '22 01:09

miku