Date range listing unexpected behaviour when using EU date format

@simfin,

TLDR:

  1. US and EU date formats show identical results
  2. Results for child-three are as expected/designed…

According the docs on dateRange:

The dateRange will filter out any pages that have a date outside (emphasis are mine) the provided dateRange

In code file /system/src/Grav/Common/Page/Collection.php lines 362-364 this is implemented as:

  • Note: $start and $end are the limits of dateRange and $date is page.date
    if ((!$start || $date >= $start) && (!$end || $date <= $end)) {
       $date_range[$path] = $slug;
    }
    

Do the math:

  • Date 31-12-2024 equals 1735603200 equals December 31st at 12:00am
  • Date 31-12-2024 13:53 equals 1735653180 equals December 31st at 1:53pm
    • December 31st at 1:53pm is larger than December 31st at 12:00am hence it will be excluded from the range.

It seems the problem must be sought between the chair and the keyboard… :wink: