I know I can use code like this to specify an individual calendar
function NewEvents() {
return DataObject::get_by_id("Cal","814")->upcomingEvents(4, "ShowEventOnHome = 1", "ShowOnHome = 1");
}
But is it possible to run something like below in order to grab upcoming events/announcements that are set to show on home for every calendar throughout a site?
function NewEvents() {
return DataObject::get("Cal")->upcomingEvents(4, "ShowEventOnHome = 1", "ShowOnHome = 1");
}
Thanks in advance for any advice in the right direction.
Andrew