Hey guys,
i have a problem with the UpcomingEvents function of the event_calendar module in SilverStripe 2.4. I'd like to display the next 5 events on the startpage in a sidebarbox. I tried using $UpcomingEvents directly and
function UpcomingEvents()
{
return DataObject::get_one("Calendar")->UpcomingEvents(5);
}
which I found in another thread. Both don't work. I get some HTML with empty links:
<div id="events">
<ul id="Menu1">
<li onclick="location.href = this.getElementsByTagName('a')[0].href"><a href=""></a></li>
<li onclick="location.href = this.getElementsByTagName('a')[0].href"><a href=""></a></li>
<li onclick="location.href = this.getElementsByTagName('a')[0].href"><a href=""></a></li>
<li onclick="location.href = this.getElementsByTagName('a')[0].href"><a href=""></a></li>
</ul>
</div>
and yes, I only get four of those.
Thanks for your help.
oleze