Developer forum

Forum » Templates » Calendar layout possibilities

Calendar layout possibilities


Reply

In Calendar v2, is it possible to display all days in a month (even those that doesn't have any events) and highlight the days that have one or more events?


 


I don't think it's possible to do by default, but maybe someone has made it with JavaScript or something?


Replies

 
Reply

I found out how to do it.


If anyone is trying to do the same, and can't find the way to work it, please post here and I will explain how I did it.

 
Reply

Hi Steffen


 


Enlighten us .... ;)

 
Reply

Hi Sebastian,


First, I used JavaScript to find out how many days the shown month contains, and made a loop that writes a span for each day. Each span has the day number as its ID. Then I have my calendar.


Second, I modified the template "EventListPartTemplate.html" to output a piece of JavaScript, that puts a style on the element that has the events day number as its ID. And bingo, the days that contain events are highlighted!

 
Reply

Hi Steffen,


 


Care to share example templates? A lot of people have been looking for a easy working solution for some time now.

 

You must be logged in to post in the forum