diff --git a/includes/class-hvac-community-events.php b/includes/class-hvac-community-events.php index 38e8cf37..9de13b94 100644 --- a/includes/class-hvac-community-events.php +++ b/includes/class-hvac-community-events.php @@ -863,7 +863,8 @@ class HVAC_Community_Events { } // Check for new custom edit event page (hierarchical URL) - if (is_page() && strpos($_SERVER['REQUEST_URI'], '/trainer/event/edit') !== false) { + // Using multiple detection methods for reliability + if (is_page(6177) || is_page('trainer/event/edit') || (is_page() && strpos($_SERVER['REQUEST_URI'], '/trainer/event/edit') !== false)) { $custom_template = HVAC_PLUGIN_DIR . 'templates/page-edit-event-custom.php'; HVAC_Logger::info("Loading custom edit-event template", 'Template Loader'); }