Hi all!
I have the following script:
# date/time stamp
$dt_stamp = date("Ymd.H.i.s");
# the directories
$basedir = str_replace("/","\\",dirname($_SERVER['SCRIPT_FILENAME']));
$shotdir = $basedir."\\sat.shots\\";
echo "downloading satellite snapshots...";
# load the images
$satloc = file_get_contents($basedir."\satloc.txt");
$images = explode("\n",$satloc);
for ( $i=0; $i <= count($images); $i++ )
{
$i_name = trim(basename($images[$i]));
$i_type = trim(strtolower(substr($i_name, -3)));
switch ($i_type) {
case "jpg" :
$img = loadjpeg(trim($images[$i]));
imagejpeg($img,$shotdir.$dt_stamp."-".$i_name);
break;
case "gif" :
$img = loadgif(trim($images[$i]));
imagegif($img,$shotdir.$dt_stamp."-".$i_name);
break;
}
}
echo " done.";
The script above works perfectly, well almost...
The problem is that when I run it, I don't see the message "downloading
satellite snapshots..." that I expect
to show on the browser before the images are acquired. Instead I get
"downloading satellite snapshots... done."
after the script finish execution.
Is this echo delay normal?
TIA
--
Irvin