How do I set upload related PHP directives in php.ini?

When having problems with file uploads because of the size of the files being uploaded it is worth having a look at the following php directives: memory_limit, upload_max_filesize, post_max_size, max_execution_time and max_input_time.

memory_limit Sets the amount of memory that a php script can use. By default it is 8Mb.
upload_max_filesize This sets the maximum allowed size for file uploads. Default is 2Mb.
post_max_size This is the maximum size allowed to be posted in HTML forms. Default is 8Mb.
max_execution_time The max time a php script is given before it times out expressed in seconds. Default is 30.
max_input_time The max time form data processing is given before it times out expressed in seconds. Default is 60.

You could create a php.ini in your web root directory (public_html) with the following directives:

memory_limit = 16M
upload_max_filesize = 4M 
post_max_size = 16M
max_execution_time = 150
max_input_time = 300

For a full description of core php.ini directives check the official documentation here.