While searching on the internet you might have seen when you search to increase php file size limit. You find post_max_size included in increment of max_file_size which can make you curious why you should increase post_max_size when you only want to increase the upload_max_filesize. To understand this we should first know what these both methods do in php.
What is post_max_size
Suppose your max_upload_file size is 8 MB and in a post which you are going to post or a page or a form which also includes text. So if you have 3 MB of text and 6 MB of images your post size becomes 9 MB which is more than your allowed post_max_size. You can say post_max_size is super hero for uploading and if you want to increase upload_max_filesize you should also increase post_max_size with it.
What is upload_max_filesize
This is the size which is allowed to upload files. If upload_max_filesize is 10MB this means you cannot upload files more than 10MB.
What is max_execution_time
In PHP max_execution time is when you give a task to server to perform. As server is also a computer and the task you give let’s say to upload CSV or .xml file. Server takes line to line and start executing the files or posts whatever task you have given to perform. max_execution_time is the time after which server will abort the execution if that’s not complete. So when you increase post_max_size and upload_max_file_size you are giving extra work to server. In this case you should also increase max_execution_Time as well.
How to handle these all things just open this post and it tells you how you can change upload_max_filesize, post_max_size and max_execution_time. In different ways through cPAnel, php.ini, .htaccess and WordPress functions.php or wp-config.php
How to increase maximum upload size, post size and execution time