MEC Hooks
You can find all of the MEC Hooks action and filter hooks for interacting with another piece of code in the following list:
Category Taxonomy MEC Hooks
templates/taxonomy-mec-category.php
do_action('mec_before_main_content');
do_action('mec_before_events_loop');
do_action('mec_after_events_loop');
do_action('mec_after_main_content');
Single page
templates/single-mec-events.php
do_action('mec_before_main_content');
do_action('mec_after_main_content');
Archive
templates/archive-mec-events.php
do_action('mec_before_main_content');
do_action('mec_before_events_loop');
do_action('mec_after_events_loop');
do_action('mec_after_main_content');
Shortcode Hooks
do_action('mec_agenda_skin_head');
do_action('mec_available_spot_skin_head');
do_action('mec_carousel_skin_head');
do_action('mec_countdown_skin_head');
do_action('mec_cover_skin_head');
do_action('mec_daily_skin_head');
do_action('mec_full_skin_head');
do_action('mec_grid_skin_head');
do_action('mec_list_skin_head');
do_action('mec_map_skin_head');
do_action('mec_masonry_skin_head');
do_action('mec_monthly_skin_head');
do_action('mec_slider_skin_head');
do_action('mec_timetable_skin_head');
do_action('mec_weekly_skin_head');
do_action('mec_yearly_skin_head');
A few examples
MEC single page
function single_mec_before_main_content() {
if ( is_singular( 'mec-events' ) ) {
echo '<div><h3>single event page</h3></div>';
}
}
add_action('mec_before_main_content','single_mec_before_main_content');
MEC archive page
function archive_mec_before_main_content() {
if ( is_post_type_archive( 'mec-events' ) ) {
echo '<div><h3>archive events page</h3></div>';
}
}
add_action('mec_before_main_content','archive_mec_before_main_content');
We also suggest seeing the list of Conditional Tags used in this article. Refer to the link below.
Report Out Dated Content
If you think the content of this page does not reflect updated information, please let us know.