how would I put a timeout on a function call?
Let's say I was echo-ing lots of data and I only wanted to do that for 20 seconds.
How would I stop the function call after 20 seconds, and continue running the rest of the script?
Set a timer variable before starting your loop. Check it on each pass. If > 20 seconds have elapsed, break.
Hint: the time() function returns a number of seconds.
it's just one function call:
echo $aFewMegsOfData
//stop after 20 seconds
how would I do that?