Ik deed meestal zoiets als dit:
<?php
list($m1, $y1) = explode($_1stdate);
list($m2, $y2) = explode($_2nddate);
$date1 = "$y1-$m1-01";
$date2 = "$y2-$m2-" . date("t", mktime(0,0,0,$m2, 1, $y2));
$sql = "SELECT *
FROM `inspection_report`
WHERE DATE(Inspection_datetime) BETWEEN '$date1' AND '$date2'";
Let op:voor de eenvoud voeg ik geen formuliervalidaties toe.