Hi @lukenc ,
I installed Events Manager and saw that my custom captions totally disappeared. Only the default image captions showed up.
I found code in Events Manager that takes over the WordPress gallery shortcode to “check for recurring events.” That’s what their source code comment says. I’m not sure why they’d need to override the gallery shortcode to do that.
GIC overrides the gallery shortcode so we can use a filter to customize gallery captions (a long overdue feature request).
Anyway, the Events Manager version wins because they use a hook with a super low priority (1000).
If you want GIC to win the override, you can add this hook to your child theme’s functions.php or use a code snippets plugin.
// Force GIC to override Event Manager's override for the gallery shortcode.
function mlc_wp_gallery_override_init() {
remove_shortcode('gallery');
add_shortcode('gallery', 'galimgcaps_gallery_shortcode');
}
add_action('init','mlc_wp_gallery_override_init', 1001);
Obviously, change mlc_wp_gallery_override_init to your function name.
You’ll need to check your Events Manager content for side effects.
Thanks!