I'm using the calendar module to post events on a site. I want three upcoming events to post on my homepage. However, if there are no upcoming events, I'd like to display the three most recent events. I can figure out how to post both 3 upcoming events and 3 past events all the time, but not how to use an if clause. It seems the only way to post upcoming and past is to call the calendar module twice ... like so.
{cms_module module="Calendar" display="upcominglist" upcominglisttemplate="home" limit=3}
{cms_module module="Calendar" display="pastlist" upcominglisttemplate="home" reverse="true" limit=3}
Any help on this would be appreciated.
Thanks.
Natalie
Calendar module: Post past events only if no upcoming events
-
- New Member
- Posts: 8
- Joined: Tue Nov 04, 2008 3:45 pm
Re: Calendar module: Post past events only if no upcoming events
in the wiki, in the share your tag page, there is an example called "count news items"
I think you can make a similar tag to count upcoming events.. and then you can build the if clause..
I think you can make a similar tag to count upcoming events.. and then you can build the if clause..