laravel eloquent whereDateBetween
snippet in php

laravel eloquent whereDateBetween

user7084

$from = date('2018-01-01');
$to = date('2018-05-02');

Reservation::whereBetween('reservation_from', [$from, $to])->get();