The easiest way to group your events by month is to place them into month folders. That's currently what we do. We've even gotten to the point where when an event is created, it is automatically placed in the corresponding "month" folder.
But if you'd prefer not to use that approach, you could sort them, loop through them and then group them by date programatically. There is an example on this forum of how you can group items together. Here a snippet of what we've used in the past for this approach:
Group nodes by month
I am building an event listing page and need to be able to group events by month as shown in the screen mock-up below:
http://www.testsite.3sixtywebdesign.co.uk/corrymeela/events.html
Is this possible with razor and what is the best way of going about it?
The easiest way to group your events by month is to place them into month folders. That's currently what we do. We've even gotten to the point where when an event is created, it is automatically placed in the corresponding "month" folder.
But if you'd prefer not to use that approach, you could sort them, loop through them and then group them by date programatically. There is an example on this forum of how you can group items together. Here a snippet of what we've used in the past for this approach:
Hope that's helpful!
is working on a reply...