I have a function like this that may run for 20 minutes:
function test($videoarray)
{
for($i;$i<100;$i++)
if(converVideo($videoarray[$i]))
{
echo 'video number '.$i.' has been convert';
}
else
{
echo 'video number '.$i.' Is too large.';
}
}
During this time I wish I could see the messages live, for example with Ajax/PHP.
Is it possible?
Desired result:
1st min: video number 1 has been converted.
2nd min: video number 2 is too large.
,
.
.