Events Manager Extended is a great WordPress plugin that allows you to do all sorts of things events related on your website.

I recently was trying to figure out a way to only display an event end date if there was one, otherwise don’t display it at all. Luckily, Events Manager Extended has a feature just for that!

How to do it

When you go to the Settings menu, you will see a “Default event list format” section. This is where you style the events in a list if you so choose.  To have an end date add to your list only if there is an end date set, use the following code:

[events_if tag="#ESC_{j M Y}" notvalue="#ESC@_{j M Y}"] This date is only printed if different from start date: #@_{- j M Y} [/events_if]

This code checks to see if both the start date and the end date are different. If they are, then it displays the code inbetween the [events if] tags.

It doesn’t stop there!

You are not limited to using conditional tags only in event lists. You can use them in most of the format settings of Events Manager Extended.

There are so many different ways to use these tags. To see more details on them check out the Events Manager Extended plugin site.