I like to pull information fra this site: http://www.danskenetbank.dk/services/valuta/valuta.htm
I use this snippet to get the entire page:
$file = "http://www.danskenetbank.dk/services/valuta/valuta.htm";
$open = fopen($file, "r");
$input = fread($open, 15000);
fclose($open);
Afterwords I would like to get a certain row ex. DEM. I've tried the following regex, but it's too greedy.
ereg("<tr>(.DEM.)(</tr>){1}", $input, $output);
How can I get everything between <tr> and </tr> where DEM is represented and how do I split the tabelscells into an array afterwords?
P.S. I can only use POSIX-functions.
Thanks,
Doeleman