skip to Main Content

difference between two times Laravel Carbon

I want to check difference between two times in Laravel (the day is not needed) Carbon::createFromTimeString($this->debut) ->diffInHours(Carbon::createFromTimeString($this->fin)) if $this->debut = '08:00:00' and $this->fin = '02:00:00' the expected result is 18 but I have 6 How can I get the correct…

VIEW QUESTION
Back To Top
Search