title: How to prevent php timeout
body: <p>I'm currently having a timeout error with my massiv data import.
  The php script takes about 90 minutes to complete but after exactly 60 minutes it returns error 500.
  I'm calling the php script from a c# program like this:</p>
  
  <pre><code>try
  {
      WebRequest request = WebRequest.Create("https://path/to/my/script");
      request.Timeout = 7200000;
      request.Credentials = CredentialCache.DefaultCredentials;
      WebResponse response = request.GetResponse();
      ...
  }
  catch(WebException ex)
  {
      ...
  }
  </code></pre>
  
  <p>I already tried some things, but none of them solved the problem:</p>
  
  <ul>
  <li>set "max_execution_time" to 7200 in php.ini </li>
  <li>set "session.gc_maxlifetime" to 7200 in php.ini </li>
  <li>call set_time_limit(0); at the start of the php function</li>
  </ul>