0

Zip files over 65mb won't upload to my database and file folder. The server allows 500MB and php allows 128MB

I have up the size of the file to determine how large the file can be before it stops working.

This is the form

Enter Your Account Email:

Upload File:
upload

And this is the code to add the files. It works but stops at a certain size.

 if (!in_array($extension, ['mp3', 'wma', 'wav', 'zip'])) {
    echo "Your file extension must be .mov, .wmv, .mp4 or .zip";
} elseif ($_FILES['myfile']['size'] > 100000000) { // file shouldn't be larger than 1Gigabyte
    echo "File too large!";

To upload zip files at least 125MB

John Conde
  • 217,595
  • 99
  • 455
  • 496

1 Answers1

0

first create .htaccess file and copy paste it in .htaccess file in your root directory.

When you make change on php configration through .htaccess you should put configrations in IfModule tag,.

<IfModule mod_php5.c>
   php_value upload_max_filesize 100M
   php_value post_max_size 100M
</IfModule> 
Mohit Kumar
  • 952
  • 2
  • 7
  • 18
  • Like this file_uploads = On upload_max_filesize = 5000M post_max_size = 5000M Yet still doesn't work – Victorious May 26 '19 at 01:08
  • Nope it still did not go through at (96,845,006 bytes (96.8 MB on disk)) I don't know why it is not working. The php.ini is in the main folder should it be in the folder the php file is in, but in that case I would need more than one php.ini file. – Victorious May 26 '19 at 01:14
  • I have tried this in the .htacess files and nothing php_value upload_max_filesize 100M php_value post_max_size 100M – Victorious May 26 '19 at 02:07