Make interval of time laravel
i have 2 time.
start time is 10.00 and end time is 12.00 .
so i want to make like this :
10.15 10.30 10.45 until 12.00.
the interval of this time is 12.
So how can i to make the interval of the time?
for($i=$time['from'];$i<$time['end'];$i=Carbon::createFromFormat('H:i', $i)->addMinutes(15))
{
$time_interval[$i]=Carbon::createFromFormat('H:i', $i)->toTimeString(); }
how to know if the time have passed the end time?
can i use like this $i<
from Laravel Questions and Answers https://laravelquestions.com/laravel/make-interval-of-time-laravel/
via Lzo Media
No comments:
Post a Comment