The Grid The Events Calendar
-
Hello,
I’m trying to create a custom skin for The Grid plugin that will display the start date of an event post above title and excerpt. Since I’m a newbie, I’m pretty lost…but through trial and error close to a solution. Any coding advice would be much appreciated.Here’s where I’m at: below is the snipet of code in The Grid skin that displays the custom post of the Event Calendar:
$output .= $tg_el->get_content_wrapper_start();
$output .= $tg_el->get_content_wrapper_start(); // get a meta data value for the an item $output .= $tg_el->get_item_meta('_EventStartDate,'); $output .= $tg_el->get_the_title(); $output .= $tg_el->get_the_excerpt(); $output .= $tg_el->get_read_more_button($readmore_args);
It works and it’s pretty close to what I want except _EventStartDate displays a numeric value (e.g. 2016-07-04 08:00:00). I want a standard value like: ‘July 4, 2016.’
According to the Events Calendar website, the function that does this is:
the tribe_get_start_date()
( source: https://theeventscalendar.com/function/tribe_get_start_date/ )Trouble is, I don’t know how to code it correct in the above context. Any suggestions? I feel like I’m close… just not understanding the ‘get_item_meta’ function and how to use tribe_get_start_date().
- The topic ‘The Grid The Events Calendar’ is closed to new replies.