PDA

View Full Version : Max Upload size only 250kb?



hddweb
07-18-2005, 09:12 PM
I'm having troubles with my php upload script, everything was working fine yesterday but suddenly today the largest file size the script is willing to upload is 250kb. Files smaller then 250kb still load fine.

I've checked php.ini and I have (and have always had) post_max_size set at 20M, upload_max_filesize set at 20M, and the rest you can see at http://www.blogupload.com/phpinfo. In the upload script I have: <input type="hidden" name="MAX_FILE_SIZE" value="20240000"> in the form field as well. I've tried adding "LimitRequestBody 40960000" in httpd.conf also yet still the script will not taking anything over 250kb.

Anyone know of any other configs on the server that control size of uploaded files? I ask because we were having network problems so Hivelocity's techs were going through the server trying to fix the problem so they might have changed somethin gon accident.

Thanks.

jmstacey
07-18-2005, 09:54 PM
Does it give you an error about the filesize or does it timeout or...

hddweb
07-18-2005, 10:49 PM
nope it tells me nothing. In my upload code I have:

if(move_uploaded_files(.......))
echo "File Uplaoded";
else
echo "File was not uploaded successfully";

Once I hit upload the status bar crawls so the server is working, then it just says: "File was not uploaded successfully". I'm pretty sure its not the actual upload script since files under 250kb seem to work fine.

jmstacey
07-19-2005, 06:21 AM
There is a max_upload_filesize directive that is also set with a 2mb default, might want to make sure that's set correctly too.

There are also several other configurations you will need to look at, for example post_max_size.
YOu might try a different file upload method:
http://us2.php.net/manual/en/features.file-upload.php

hddweb
07-19-2005, 07:56 AM
Hmm I extended the max input time and it seems to be working now...weird..thanks jmstacey!