PHP fopen forloops
<p>I'm not exactly sure why this isn't working I tried googling it to see if there was a answer a lot of them came up with a foreachloop instead of regular for loops can someone explain to me why this isn't working.</p>

<pre><code>&lt;?php
$list = array("GOOG", "AAP", "MSFT");

    for($i=0; $i&lt;3; $i++)
    {
        echo "why isn't this working &lt;br&gt;";

        $fp = fopen ("http://finance.yahoo.com/d/quotes.csv?s=GOOG&amp;f=sl1ve1x&amp;e=.csv","r");
        $data = fgetcsv ($fp, 1000, ",");
        $exit = str_replace('"',"",$data[3]);
        $exchange = str_replace('"',"",$data[4]);

        echo "$data[0] &lt;br&gt;";
        echo "$data[1] &lt;br&gt;";
        echo "$data[2] &lt;br&gt;";

    }
?&gt;
</code></pre>

<p>I expected it to print google info 3 times it doesn't if I take fopen out by itself once it works but if I do it multiple times it just doesn't do anything what I expected is </p>

<p>output ex </p>

<pre><code>why isn't this work
Goog
8398
789
why isn't this work
Goog
8398
789
why isn't this work
Goog
8398
789
</code></pre>
