Forum Moderators: coopster

Message Too Old, No Replies

how to store variables permanently

         

zozzen

5:53 pm on Nov 28, 2007 (gmt 0)

10+ Year Member



Hi, very new to php, I'm wondering if it's possible to store a variable permanently.

Let say, I fetch the stock quote from yahoo like this:

<?php
$fp = fopen ("http://finance.yahoo.com/d/quotes.csv?s=MSFT&f=sl1d1t1c1ohgv&e=.csv","r");
$data = fgetcsv ($fp, 1000, ",")
?>

<?php
fclose ($fp);
?>

And I'll get the $data[0....8], how can i store them permanently?

Thanks alot!

eelixduppy

6:29 pm on Nov 28, 2007 (gmt 0)



Write it to a file [php.net] or store it in a database [php.net].

zozzen

1:11 am on Nov 29, 2007 (gmt 0)

10+ Year Member



thanks a lot! the php manual is so great!