MEC Events, Formatting Time, Location

Hi,

  1. I am pulling in MEC Events through a looper and would like to display the time. I am using this code currently but the format part isn’t working to display the minutes correctly. Without a format it only shows 1 minute place instead of two. How can I get it to display 10:00 instead of 10:0 ? I could add an extra zero, but I have some events that start on the half hour.

{{dc:post:meta key=“mec_start_time_hour”}}:{{dc:post:meta key=“mec_start_time_minutes” type=“date” format=“i”}} {{dc:post:meta key=“mec_start_time_ampm”}}

  1. Is there a way to pull in an event’s location? I have tried several things I have found in the forum, but nothing appears to be working. The only answer that I find that could work asks for a specific ID, but that only pulls in one location…I’d like for this to be variable based on the event itself.

Thanks!
Jen

Hey Jen,

Sadly, there is no solution to both of your queries. If you use the format attribute in the MEC DC, the DC will not work. Regarding the location, it’s really only currently reachable manually or using a specific ID.

If you need us to develop a custom solution for you, check out our Elite service here: https://elite.theme.co/

Thanks.

Thanks! That is what I figured the answer would be so I used ACF to create a workaround by adding a start date and the city in custom fields and using those to pull in the data I needed.

Thanks again,
Jen

Hey Jen,

You’re welcome! If you have any other concerns or clarifications regarding our theme features, feel free to open up a new thread.

Thank you.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.