GRY
GRY

Reputation: 724

WAMP max_upload_filesize

I am writing a PHP script to upload and re-size 4 images. I have opted to use the method of giving 4 inputs the same name (an array):

<input type="file" name = "userfile[]" id="file1" />
<input type="file" name = "userfile[]" id="file2" />
<input type="file" name = "userfile[]" id="file3" />
<input type="file" name = "userfile[]" id="file4" />

I have set max_upload_filesize in wamp to 50M. I have verified the max_uploads is set to default (20). I have restarted all services and run php_info to verify this php.ini file was loaded.

My form-receiver page only does one thing:

var_dump($_FILES["userfile"]);

This works well, until file size approaches 8MB. When the size of the uploaded files approache 8MB I get the error Notice: Undefined index: userfile in C:\wamp\www\uploader\file_upload.php on line 2

I have re-sized one image, pushing it up to 8MB size, and then tried ot upload 1 single file- this recreates the error. I am certain that an 8MB limit exists here.

Can anyone help me solve this?

Upvotes: 0

Views: 956

Answers (1)

Nikola K.
Nikola K.

Reputation: 7155

Find post_max_size and increase it's value.

Also, it's upload_max_filesize, not max_upload_filesize.

Upvotes: 2

Related Questions