php parallel curl request with for
<p>This is code I wrote for fetching multiple URLs in parallel...</p>

<pre><code>$nodes = array($url1, $url2, $url3);
$node_count = count($nodes);

$curl_arr = array();
$master = curl_multi_init();

for($i = 0; $i &lt; $node_count; $i++)
{
    $url =$nodes[$i];
    $curl_arr[$i] = curl_init($url);
    curl_setopt($curl_arr[$i], CURLOPT_RETURNTRANSFER, true);
    curl_multi_add_handle($master, $curl_arr[$i]);
}

do {
    curl_multi_exec($master,$running);
} while($running &gt; 0);


for($i = 0; $i &lt; $node_count; $i++)
{
    $results[] = curl_multi_getcontent  ( $curl_arr[$i]  );
}
print_r($results);
</code></pre>

<p>Is this part really parallel?</p>

<pre><code>for($i = 0; $i &lt; $node_count; $i++)
{
    $results[] = curl_multi_getcontent  ( $curl_arr[$i]  );
}
</code></pre>

<p>Can any one tell me?</p>
