Home Forums Events Calendar Add-on Custom Style for Past Events in Calendar

Custom Style for Past Events in Calendar

Posted: January 28, 2014 at 10:35 am


January 28, 2014 at 10:35 am


I am trying to figure out how to grey out/color past events in the calendar view so that they look distinctly different from upcoming events. I couldn’t see any unique style that was given to past events. Is there any way for me to accomplish this?



  • Support Staff

January 28, 2014 at 11:13 am

Hi artbarslo,

Which version of the calendar are you currently using?

Expired events should have the class ‘expired’ so can be styled accordingly. However, are the previous events closed for registration or still open?


January 28, 2014 at 12:40 pm

Hi, I am using version Version

Yes, the previous events are closed… however they do not have an .expired class to them.

Here is a link to the page I am referring to:

Thank you so much for your help.

Jonathan Wilson

January 28, 2014 at 3:43 pm

Hi there,

Can you check which version of the Calendar add-on you are running? The latest version should have the expired class.


January 28, 2014 at 5:07 pm

Calendar Add-on Version 2.2.2.p


January 29, 2014 at 5:45 am


We have confirmed there is something wrong here, and have raised a developer ticket to look into it.


  • Support Staff

January 29, 2014 at 12:43 pm

We found a logic issue in the calendar plugin. We’ll be releasing a fix in the next update to the calendar plugin. If you want to apply the fix manually, you can open up the calendar plugin’s espresso-calendar.php file and remove the else statement that goes after the if that starts on line 600. You’ll end up with this:

if ( $not_open ) 
    $events[ $cntr ]['className'] = 'not-open';


January 29, 2014 at 12:56 pm

Yeah that did it. Thanks so much.

The support post ‘Custom Style for Past Events in Calendar’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Status: closed

Updated by  artbarslo 5 years, 7 months ago ago

Topic Tags


This topic is: resolved
Do NOT follow this link or you will be banned from the site!