But then I seem to be unable to use the filterby and sortby function on the collection ?? It seems like it doesn’t filter/sort at all…
$events = $pages->find("events")->children()->sortBy("startdate", "asc");
or $events = $pages->find("events")->children()->filterby("enddate", '>=', time());
I did a quick test with renaming the field to “date”, and then it seems to be working? Is it somehow “hardcoded” that date fields should be named “date”?
Thank you both @texnixe & @lukasbestle, your callback tip worked like a charm, and I upon a quick test I think the sorting should be fixed too now upon changing the format to yyy-mm-dd.
You guys make kirby great. This kind of support on a weekday at 10.30pm is simply outstanding.