I have a function where I want to delay a certain call in the middle, but I don't want to stop the whole function. Even after the last line I want the part I delayed to run after a designated time. Here's an example of what I mean:
function delayInMiddle()
{
function call 1
if(some condition met in 30 seconds)
{function call 2}
function call 3
}
I want to have function 1 called, check for function 2, continue to function call 3, then go back and do function call 2 in 30 seconds. Is this possible in php?