title: Is it possible to send multiple file requests at the same time in PHP?
body: <p>I am building an application which makes several page requests using PHP (15 calls for instance). It is important that I have the information from all of these pages before I continue with the rest of my application.</p>
  
  <p>Currently I have a setup to the following effect:</p>
  
  <pre><code>for ($i = 0; $i &lt; 15; $i++){
    $var = file_get_contents('http://example.com');
    $array[i] = $var;
  }
  </code></pre>
  
  <p>I then use the array for the rest of my application.</p>
  
  <p>The problem i'm having is that obviously 15 executions of file_get_contents takes a long time, and I was wondering if there is a way in PHP to send off 15 page content requests at the same time, and then continue with the application when all 15 results have been obtained?</p>