Skip to content
Advertisement

Set timeout in WordPress hook

I need help here.

I have taken 1-2 days to figure out how to redirect a user from one page to another page AFTER a few or 10 secs

I know there is sleep() function I need to be fixed but where, I am not sure about it:

I have a sample code here

JavaScript

I am awaiting a response

Thank you in advance

Advertisement

Answer

You can use the PHP sleep() function to delay execution of a script.

User contributions licensed under: CC BY-SA
9 People found this is helpful
Advertisement