php hour between

Solutions on MaxInterview for php hour between by the best coders in the world

showing results for - "php hour between"
Lorenzo
13 Oct 2020
1$currentTime = (new DateTime('01:00'))->modify('+1 day');
2$startTime = new DateTime('22:00');
3$endTime = (new DateTime('07:00'))->modify('+1 day');
4
5if ($currentTime >= $startTime && $currentTime <= $endTime) {
6    // Do something
7}