1

I am doing a file upload using PHP, which works fine for a file of size 2.8MB on my localhost - but not my Mediatemple GS host. Files smaller than 2MB work fine, but anything larger seems to not work... I am not getting any error message but when the upload finishes, the file is not found in the uploads directory...

I googled around, and I added the following lines to the .htaccess file:

php_value memory_limit 120M
php_value max_execution_time 120
php_value upload_max_filesize 10G
php_value post_max_size 10G

I know some of the above values are a overkill, but even then, this does not seem to help... Anything else I might be missing?

jack33
  • 181
  • 1
  • 1
  • 6
  • 3
    Your webhost may not allow those php_value's to be overwritten by htaccess. I would check with them. And a bit overkill is an understatement, this may also have an effect. I would set them to realistic values. IE: post_max_size 120M given that your memory limit is 120M. – Jim Jul 24 '10 at 16:41
  • Do apache configs even support G? See premiso's comment about realistic values. Try expressing it in megabytes. – AvatarKava Jul 24 '10 at 16:48

2 Answers2

3

The one you missed is max_input_time, and do check whether your edits are reflected in phpinfo();.

Wrikken
  • 69,272
  • 8
  • 97
  • 136
0

Check the phpinfo() and look for these four values - it's possible that the changes you think you're making haven't been applied, or that something else is overriding your changes. The values you've changed look correct to me.

John Fiala
  • 4,561
  • 3
  • 30
  • 26