Marek,
Your pattern should look like:
$pattern = "([[:digit:]]{6}0425\.jpg)";
BINGO!
This will give you the image name, but remember that ereg works on
single lines and also the image might be taken at some time around
4:25. So you need a while loop to read the html line by line, in the
loop t
Your pattern should look like:
$pattern = "([[:digit:]]{6}0425\.jpg)";
This will give you the image name, but remember that ereg works on
single lines and also the image might be taken at some time around 4:25.
So you need a while loop to read the html line by line, in the loop try
to match the
[snip]
http://rsd.gsfc.nasa.gov/goesg/earth/Weather/GMS-5/jpg/vis/4km/";;
if (!($fp = fopen($URLbase, "r")))
{
echo "Could not open the url";
exit;
}
$contents = fread($fp, 100);
fclose($fp);
?>
[/snip]
Was that r
New to the list, so I hope I'm in the right place.
I'm trying to write a small php function which checks a page filled
with a list of satellite images of earth, and loads the latest one to
have been taken at 4:25 in the morning, when the view is most complete
(full credit to be given to the ori
4 matches
Mail list logo