Skip to content

mc_draw_upcoming_event

github-actions[bot] edited this page Jun 3, 2026 · 4 revisions

Draw a custom template for upcoming events. Returning any non-empty string short circuits other template settings.

Auto-generated Example

add_filter(
   'mc_draw_upcoming_event',
    function(
        string $item,
        array $details,
        string $template,
        array $args
    ) {
        // Your code here.
        return $item;
    },
    10,
    4
);

Parameters

  • string $item Empty string before event template is drawn.
  • array $details Associative array of event template tags.
  • string $template Template string passed from widget or shortcode.
  • array $args Associative array holding the arguments used to generate this list of upcoming events.

Returns

string Event template details.

Files

apply_filters( 'mc_draw_upcoming_event', $item, $details, $args['template'], $args )
apply_filters( 'mc_draw_upcoming_event', '', $details, $template, $type )

← All Hooks

Clone this wiki locally