I was using a PHP script to convert Yahoo finance quotes to an HTML web page. But suddenly the web page stopped showing the data after a year of working perfectly and there were no code changes at all. Here is my code:
<table>
<tr>
<?php $fp = fopen ("http://finance.yahoo.com/d/quotes.csv?s=VIP&f=l1c1p2rj1&e=.csv","r");
$data = fgetcsv ($fp, 1000, ",") ?>
<td>Vimpel-Communications</td>
<td><?php echo $data[0] ?></td>
<td><?php echo $data[1] ?></td>
<td><?php echo $data[2] ?></td>
<td><?php echo $data[3] ?></td>
<td><?php echo $data[4] ?></td>
<td><?php echo $data[5] ?></td>
</tr>
</table>
And here is a test page of the actual site: http://bricadr.com/test.php
Can anyone help or does anyone know what happened, or how I can fix this? Additionally, if anyone has a sever, can you see if this code works on your server? Perhaps my hosting company turned off some functionality that allowed this to previously work.
Thank you in advance!
Brian
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…