I am trying to create an upload form but it wont save large files and doesn't give any errors either.
I don't know where exactly the limit is but a 65kb image saves fine, whereas a 4mb image does not. The uploads folder is simply empty for larger files. I can verify it's uploading and see the request sent...however the server uploads folder remains empty.
Here is my upload script:
<?php
$ds = DIRECTORY_SEPARATOR;
$storeFolder = 'uploads';
if (!empty($_FILES)) {
$tempFile = $_FILES['file']['tmp_name'];
$targetPath = dirname( __FILE__ ) . $ds. $storeFolder . $ds;
$targetFile = $targetPath. $_FILES['file']['name'];
move_uploaded_file($tempFile,$targetFile);
}
?>
And here are the relevant settings I have in my php.ini:
max_input_time = -1
memory_limit = 1500M
post_max_size = 1500M
file_uploads = On
upload_max_filesize = 1500M
max_file_uploads = 100
allow_url_fopen = On
This is for internal use only if you're wondering about the odd settings. As far as my actual upload page, it's just a simple html snipped from W3 schools.
This is running on Apache on an Ubuntu server. The script seems to work fine in a Windows WAMP setup. Also, the permissions on the directory are correct.