The forums ran from 2008-2020 and are now closed and viewable here as an archive.
I would like to have a script PHP or JS anything.
I would like to redirect URL based on time of the day and (not constantly keep reloading in a loop).
I would like to redirect 3 url, a b and c, depending on time of the day, a.php will load from 6:31 to 14:30, then b.php from 14:31 to 22:30, and c.php from 22:31 to 6:30.
Maybe if using a invisible iFRAME works, thats also fine i guess.
Thanks a lot in advance
Interesting. What have you tried so far?
I have tried Php script
I have tried is
But where it works the prob is it goes in a loop of loading the same URL
Where it detects the same URL is correct for the particular time of day. It won’t load another URL when the time changes
if ($hour >= 6 && $hour <= 14)
window.location.href = “normal.php”;
else if ($hour >= 14 && $hour <= 22)
window.location.href = “vodafone.php”;