Can file uploads time out in PHP?

Ben McRae picture Ben McRae · Feb 23, 2009 · Viewed 68.5k times · Source

Hi im quite new to PHP, i have created a form for very large csv files to be uploaded to my server. Some one mentioned to me that the browser can time out due to the uploading file being to big, is this true? and if so, can it be prevented?

Thanks for your help!

Answer

Ionuț G. Stan picture Ionuț G. Stan · Feb 23, 2009

You need a proper value for the following php.ini settings:

  1. max_input_time (not max_execution_time!)
  2. upload_max_filesize
  3. post_max_size

and maybe

  1. memory_limit