Well, I would like to add my 2 cents here.
I'm using shared webhosting and I tackled this problem many times, tried to resolve it on my own but to no avail.
Finally I managed to resolve it through checking various web sources and contacting my hosting service provider. My questions were "How can I change php value memory_limit
in shared webhosting?", "How can I change php value upload_max_filesize
in shared webhosting?", "How can I change php value max_input_vars
in shared webhosting?", "How can I change php value max_execution_time
in shared webhosting?", "How can I change php value max_input_time
in shared webhosting?" and many more by configuring or changing php.ini or .htaccess
file. I tried to change them but problems arose. Finally I contacted my hosting provider, and it turns out that I set my php to native, they changed it to php 5.6, here is their answer:
"Your PHP was set to 'native' mode which means you can't override
those values. I've changed you to just '5.6' so you should be good to
go."
After that I connected my website through ftp Filezilla, also don't forget to make both your ftp service to show hidden files, and your local computer to do so, because .htaccess
file was hidden in my local laptop and in my website. It was available in public_html folder, I just downloaded it and added the following codes to the end of the file and then uploaded it back to the server:
php_value memory_limit 256M
php_value post_max_size 256M
php_value upload_max_filesize 64M
php_value max_input_vars 1800
php_value max_execution_time 300
php_value max_input_time 300
Everything is working properly for the time being, if any of you overcome with some problems please write here and warn me so that I can change the above-shown codes. By the way, I also upload some pictures which shows the change.
One more thing I almost forgot to mention ZipArchive installation on your shared webhosting service, I managed that requirement to tick by just going to php settings through my cpanel, click on php selector extensions and then tick zip section, that's all.
Thanks.
PS: I'm open to good practices, and if you see any bad practice here please let me know, I'll try to change them. Thanks.