# CLAUDE.md This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. ## 🏗️ Architecture Overview This is a WordPress plugin (`HVAC Community Events`) that provides a comprehensive event management system for HVAC trainers. Key architectural components: - **Main Plugin**: `hvac-community-events.php` (entry point) - **Core Classes**: Singleton pattern, located in `includes/class-*.php` - **Template System**: Custom templates in `templates/` with hierarchical URLs - **Asset Management**: Conditional loading via `HVAC_Scripts_Styles` - **User Roles**: `hvac_trainer` (standard) and `hvac_master_trainer` (admin-level) - **URL Structure**: Hierarchical (`/trainer/dashboard/`, `/master-trainer/master-dashboard/`) ## 🚀 Essential Commands ### Deployment ```bash # Deploy to staging (primary command) scripts/deploy.sh staging # Deploy to production (requires explicit user confirmation) scripts/deploy.sh production # Pre-deployment validation (ALWAYS run first) scripts/pre-deployment-check.sh # Post-deployment verification scripts/verify-plugin-fixes.sh ``` ### Testing ```bash # Run E2E tests with Playwright node test-all-features.js # Run specific feature tests node test-trainer-features.js node test-master-dashboard.js # Test on staging environment UPSKILL_STAGING_URL="https://upskill-staging.measurequick.com" node test-*.js ``` ### Development ```bash # WordPress CLI operations (when on server) wp rewrite flush wp eval 'HVAC_Page_Manager::create_required_pages();' wp post meta update [PAGE_ID] _wp_page_template templates/page-*.php # Clear caches after changes scripts/clear-staging-cache.sh ``` ## 📚 Documentation For comprehensive information, see: - **[docs/README.md](docs/README.md)** - Overview and navigation - **[docs/CONFIGURATION.md](docs/CONFIGURATION.md)** - System configuration and architecture - **[docs/DEVELOPMENT-GUIDE.md](docs/DEVELOPMENT-GUIDE.md)** - Development standards and workflow - **[docs/TROUBLESHOOTING.md](docs/TROUBLESHOOTING.md)** - Common issues and solutions - **[docs/API-REFERENCE.md](docs/API-REFERENCE.md)** - Complete API documentation ### 🚀 Deployment Guidelines - **ALWAYS** use `scripts/deploy.sh staging` for staging deployments - **NEVER** deploy to production without explicit user request - **ALWAYS** run `bin/pre-deployment-check.sh` before any deployment - **ALWAYS** verify deployment with `scripts/verify-plugin-fixes.sh` - Production deployments require double confirmation ### 🎯 WordPress Best Practices #### Security First ```php // Always escape output echo esc_html($user_input); echo esc_url($link); echo esc_attr($attribute); // Always sanitize input $clean_data = sanitize_text_field($_POST['data']); $clean_email = sanitize_email($_POST['email']); // Always verify nonces wp_verify_nonce($_POST['nonce'], 'action_name'); // Always check capabilities if (!current_user_can('required_capability')) { wp_die('Insufficient permissions'); } ``` #### Code Standards - Follow WordPress Coding Standards - Use prefixed function/class names (`HVAC_`) - Never use PHP namespaces (WordPress compatibility) - Always include WordPress header/footer in templates - Use singleton pattern for main classes #### Performance - Cache expensive queries with `wp_cache_get/set` - Load assets only on plugin pages - Use conditional loading in `HVAC_Scripts_Styles` - Optimize database queries #### Theme Integration - Plugin includes Astra theme integration - All plugin pages force full-width layout - Sidebar removal handled automatically - Body classes added: `hvac-plugin-page`, `hvac-astra-integrated` ### 🔧 Development Workflow #### Making Changes 1. Create feature branch: `git checkout -b feature/description` 2. Follow commit conventions: `feat:`, `fix:`, `docs:`, etc. 3. Test thoroughly on staging 4. Update documentation if needed 5. Deploy to staging: `scripts/deploy.sh staging` #### Testing - Use Playwright E2E tests: `npm test` - Manual testing checklist in docs/DEVELOPMENT-GUIDE.md - Always test with different user roles - Verify mobile responsiveness #### User Roles - **hvac_trainer**: Standard trainer capabilities - **hvac_master_trainer**: Advanced trainer with aggregate reporting - **Dual-role users**: Show only master trainer navigation (prevents duplicates) ### 🐛 Common Issues & Quick Fixes #### Pages Not Found (404) ```bash wp rewrite flush wp eval 'HVAC_Page_Manager::create_required_pages();' ``` #### Missing CSS/Styling - Check if `HVAC_Scripts_Styles` is loading - Verify `is_plugin_page()` detection - Ensure template has `HVAC_IN_PAGE_TEMPLATE` constant #### Sidebar Still Showing - Check Astra integration is active - Force no-sidebar via post meta update - Clear all caches #### Profile Page Issues ```bash # Update template assignment wp post meta update [PAGE_ID] _wp_page_template templates/page-trainer-profile.php ``` ### 📝 Critical Reminders #### Template Requirements - ALL templates MUST include `get_header()` and `get_footer()` - ALL templates MUST define `HVAC_IN_PAGE_TEMPLATE` constant - Use `container` class for consistent styling #### URL Structure - Hierarchical URLs: `/trainer/dashboard/`, `/trainer/profile/`, etc. - Legacy URLs automatically redirect with 301 status - Master trainer URLs: `/master-trainer/master-dashboard/` #### Asset Management - CSS/JS loaded conditionally via `HVAC_Scripts_Styles` - jQuery in no-conflict mode always - AJAX uses `hvac_ajax` object with proper nonces #### Error Handling - Always return proper AJAX responses (`wp_send_json_success/error`) - Log errors appropriately (staging vs production) - Use error codes from docs/API-REFERENCE.md ### 🚨 Never Do This - ❌ Deploy to production without user request - ❌ Skip pre-deployment validation - ❌ Use `echo` without escaping - ❌ Create standalone fixes outside plugin deployment - ❌ Add debug code to production - ❌ Modify core WordPress or theme files - ❌ Use hardcoded paths or URLs ### ✅ Always Do This - ✅ Run pre-deployment checks - ✅ Test on staging first - ✅ Escape all output - ✅ Sanitize all input - ✅ Verify user capabilities - ✅ Use WordPress coding standards - ✅ Update documentation when needed - ✅ Clear caches after deployment For detailed information on any topic, refer to the comprehensive documentation in the `docs/` directory. ## ⚠️ CRITICAL WARNING: Monitoring Infrastructure Disabled **DATE: August 8, 2025** **CRITICAL: The monitoring infrastructure is PERMANENTLY DISABLED due to causing PHP segmentation faults.** The following systems are commented out in `/includes/class-hvac-plugin.php` lines 349-372: - ❌ HVAC_Background_Jobs - ❌ HVAC_Health_Monitor - ❌ HVAC_Error_Recovery - ❌ HVAC_Security_Monitor - ❌ HVAC_Performance_Monitor - ❌ HVAC_Backup_Manager - ❌ HVAC_Cache_Optimizer **DO NOT RE-ENABLE** without thorough debugging as they crash the entire site with segfaults. See `MONITORING-DISABLED-IMPORTANT.md` for full details. ## Memory Entries - Do not make standalone 'fixes' which upload separate from the plugin deployment. Instead, always redeploy the whole plugin with your fixes. Before deploying, always remove the old versions of the plugin. Always activate and verify after plugin upload - Always use the deployment scripts to upload, activate and verify plugins for code changes - The deployment process now automatically clears Breeze cache after plugin activation through wp-cli. This ensures proper cache invalidation and prevents stale content issues. - Communication Templates system uses a modal interface with JavaScript override after wp_footer() to ensure external JS doesn't conflict. Scripts load on communication-templates page only. - When testing the UI, use playwright + screenshots which you inspect personally to verify that your features are working as intended. - URL Structure: The plugin now uses hierarchical URLs (/trainer/, /master-trainer/) implemented in June 2025. All navigation, authentication, and template loading updated accordingly. Backward compatibility maintained with 301 redirects. - **CSS Prevention System**: ALWAYS run bin/pre-deployment-check.sh before any deployment. This prevents broken templates from reaching users. All templates MUST have get_header()/get_footer() calls. - **Deployment and Verification (2025-06-17)**: Use `scripts/deploy-to-staging.sh` for deployments. Always run `scripts/verify-plugin-fixes.sh` after deployment. Plugin must be reactivated to create missing pages. Legacy redirects working at 100% success rate. Certificate reports 404 issue resolved. - **Plugin Fixes Status**: Certificate reports 404 error FIXED, legacy URL redirects enhanced and working 100%, duplicate shortcode registration removed, template URLs updated to hierarchical structure, comprehensive testing suite implemented. - **Master Dashboard CSS Fix (2025-06-18)**: Master dashboard CSS was broken due to missing get_header()/get_footer() calls in template. FIXED by adding WordPress integration, comprehensive CSS variables framework (--hvac-spacing-*, --hvac-radius-*), 200+ lines of master dashboard styles, proper AJAX handlers, and responsive design. Prevention system implemented with template validation scripts. - **Directory Reorganization (2025-06-18)**: Root directory reorganized for maintainability. Development artifacts moved to `archive/` directory with structured subdirectories. Essential files (.env, core plugin files) restored to root. Deployment scripts moved to `scripts/` directory. Plugin redeployed successfully after reorganization - all functionality verified working. - **Test Data Seeding (2025-07-10)**: Updated all test data creation scripts to include JoeMedosch@gmail.com as a master trainer (password: JoeTrainer2025@) and joe@measurequick.com with both trainer and master trainer roles. Use `bin/create-comprehensive-test-data.sh` for complete staging setup. The main staging script `bin/create-staging-test-data.sh` also includes both Joe accounts. All seeding scripts now create test_trainer (regular trainer), JoeMedosch@gmail.com (master trainer), and assign dual roles to joe@measurequick.com automatically during staging deployment. - **Complete End-to-End Testing (2025-07-15)**: Comprehensive testing suite implemented and verified on staging server. Event creation workflow fully functional with 6/6 essential form elements accessible, form submission working without errors, and data persistence verified. Certificate generation workflow 100% operational with 16 events available, 3 active download links returning HTTP 200 status, and complete event-certificate integration. All tests pass including authentication (100%), certificate interface (100%), event creation (form accessibility and submission), and data persistence across sessions. System production-ready with 85-90% test coverage achieved. - **Master Dashboard User Role Fix (2025-07-23)**: Resolved critical issue where 11 HVAC trainers with legacy `event_trainer` roles were not appearing in the master dashboard. Root cause: master dashboard code only queried for `hvac_trainer` and `hvac_master_trainer` roles, missing users with the legacy `event_trainer` role from previous development. Solution: Migrated all 11 users from `event_trainer` to `hvac_trainer` role, increasing visible trainers from 4 to 15 in master dashboard. All legacy role artifacts cleaned up. Master dashboard now shows complete trainer statistics (15 total trainers, 16 total events) and all trainer data is properly accessible to master trainer users. - **Admin Bar and Zoho CRM Enhanced Fixes (2025-07-23)**: Implemented robust fixes for admin bar hiding and Zoho CRM integration issues. Admin bar: Added multiple hook points (after_setup_theme, init, wp), centralized hiding function with global constant, PHP_INT_MAX priority filters, and user meta updates. Zoho CRM: Enhanced production detection with URL parsing, aggressive OAuth rewrite rule flushing with cache clearing, and improved refresh token handling. Both fixes include extensive debug logging. Deployed to staging. - **Event Manage Page Toolbar (2025-07-23)**: Added navigation toolbar to /trainer/event/manage/ page to match other trainer pages. Includes Dashboard, Certificate Reports, and Generate Certificates buttons with consistent styling and responsive design. Uses hierarchical URL structure. - **Trainer Page Redirects and Admin Bar Removal (2025-07-23)**: Added 301 redirects from /trainer/ to /trainer/dashboard/ and /master-trainer/ to /master-trainer/dashboard/. Removed admin bar hiding code as it's now handled by The Events Calendar plugin. Updated toolbar Dashboard link to use /trainer/dashboard/. - **Production Error Fixes (2025-07-24)**: Fixed production logging issues: Removed all debug error_log statements, added duplicate checking for OAuth query vars to prevent 153+ additions, optimized admin script loading to specific page only. Significantly reduces log noise and improves performance. - **Production Deployment Support (2025-07-24)**: Updated deployment infrastructure to support both staging and production environments. Use `scripts/deploy.sh staging` for staging deployments and `scripts/deploy.sh production` only when explicitly requested by the user. Production deployments require double confirmation to prevent accidental deployment. IMPORTANT: Only deploy to production when the user explicitly asks for production deployment. - **Manual Geocoding Trigger System Implementation (2025-08-01)**: Implemented comprehensive manual geocoding system for trainer profiles with 85% coverage success rate. System includes HVAC_Geocoding_Ajax class (includes/class-hvac-geocoding-ajax.php:47) with three AJAX endpoints: hvac_trigger_geocoding for manual geocoding operations, hvac_run_enhanced_import for CSV location data population, and hvac_get_geocoding_stats for coverage monitoring. Successfully geocoded 45 out of 53 trainer profiles across 15+ US states and 3 Canadian provinces. Fixed email field mapping issue from CSV import, correcting "Work Email" to "Email" column for proper user matching. System features Google Maps API integration with rate limiting, comprehensive error handling, and real-time statistics. Production-ready with full master trainer controls for location data management. - **Plugin Architecture Refactoring (2025-07-28)**: Implemented modular architecture with single-responsibility classes. Created HVAC_Shortcodes for centralized shortcode management, HVAC_Scripts_Styles for asset management, and HVAC_Route_Manager for URL routing. Eliminated duplicate functionality between HVAC_Plugin and HVAC_Community_Events. All components now use singleton pattern to prevent duplicate initialization. Fixed jQuery selector errors and duplicate content issues. See docs/ARCHITECTURE.md for details. - **Master Dashboard URL Fix (2025-07-29)**: Fixed critical issue where master dashboard was showing trainer dashboard content. Root cause: Both trainer and master dashboards had the same page slug "dashboard", causing WordPress to load the wrong page. Solution: Changed master dashboard URL from `/master-trainer/dashboard/` to `/master-trainer/master-dashboard/`, updated all code references, removed conflicting legacy redirects. Master dashboard now correctly displays master trainer content with aggregate statistics and trainer performance analytics. - **Event Manage Page CSS and Header Fix (2025-07-30)**: Resolved persistent CSS override and duplicate header issues on the trainer/event/manage/ page. Root causes: CSS specificity conflicts with theme styles, header being added via both template and tribe hook. Solution: Scoped all CSS rules to `.hvac-event-manage-wrapper`, moved navigation header directly into page template, disabled duplicate tribe hook, added theme override styles. Page now displays correctly with single header, proper 1200px max-width layout, 20px padding, and consistent styling matching other dashboard pages. - **Major Plugin Update - Registration Refactor and New Trainer Pages (2025-07-30)**: Implemented comprehensive updates to HVAC plugin. Registration form refactored: moved Application Details to Personal Information, renamed Business Information to Training Organization Information with TEC integration, added required Organization Logo upload, added Headquarters location fields, created conditional Training Venue section. New trainer pages created: Training Venues system (/trainer/venue/list, /trainer/venue/manage) with full CRUD operations and TEC venue integration; Trainer Profile system (/trainer/profile, /trainer/profile/edit) with photo upload, certifications, stats tracking; Training Organizers system (/trainer/organizer/list, /trainer/organizer/manage) with logo upload and headquarters tracking. All systems use AJAX forms, real-time validation, responsive design, and proper WordPress/TEC integration. - **Navigation Menu and Breadcrumb Systems (2025-07-30)**: Added comprehensive navigation system (class-hvac-trainer-navigation.php) with hierarchical menus, dropdown support, keyboard navigation, mobile hamburger menu, and active page highlighting. Implemented automatic breadcrumb system (class-hvac-breadcrumbs.php) with SEO-friendly Schema.org markup, URL-based trail generation, and multiple style options. Both systems ready for template integration. - **Staging Deployment and Testing (2025-07-30)**: Successfully deployed all trainer features to staging. Created test users (test_trainer/TestTrainer123!, test_master/TestMaster123!). Registration form changes verified live. 71% test pass rate with 4/7 trainer pages accessible. Outstanding issues: HQ fields not visible on registration, some pages need manual creation, navigation/breadcrumb template integration required. - **Navigation and Layout Fixes (2025-08-01)**: Resolved three critical UI issues: (1) Dual-role users now show only master trainer navigation to prevent duplicate menus, implemented in HVAC_Menu_System by detecting master trainer role and always returning master menu structure. (2) Removed 2-column sidebar layout on all dashboard pages through enhanced HVAC_Astra_Integration with aggressive CSS overrides, forced no-sidebar meta updates, and complete sidebar removal filters. (3) Fixed profile page template assignment to use new template with proper navigation and breadcrumbs. All fixes deployed to staging and verified through automated tests - dashboard shows single navigation in full-width layout, profile page uses new template with correct styling. - **Role Field and Certification System Implementation (2025-08-01)**: Added comprehensive user role field to registration, profile display, and profile edit with 10 role options (technician, installer, supervisor, manager, trainer, consultant, sales representative, engineer, business owner, other). Implemented advanced certification tracking system with three meta fields: date_certified (date picker), certification_type (dropdown with "Certified measureQuick Trainer" and "Certified measureQuick Champion"), and certification_status (status badges for Active/Expired/Pending/Disabled). Features sophisticated role-based access control where regular trainers see read-only certification fields while administrators and master trainers have full edit access. All 25 users automatically migrated with appropriate default values during plugin activation. System includes professional CSS styling with color-coded status badges, comprehensive server-side validation, and complete E2E test coverage. Documentation updated with access control patterns and API reference. - **Enhanced CSV Import System Implementation (2025-08-04)**: Resolved critical issue where trainer profiles were missing comprehensive information from CSV_Trainers_Import_1Aug2025.csv file. Root cause: existing import system used hardcoded data instead of reading actual CSV file containing 19 fields of trainer information. Solution: Created complete enhanced CSV import system (includes/enhanced-csv-import-from-file.php) that reads actual CSV file and imports all available fields including phone numbers, company websites, certification details, business types, and training audiences. System features: processes 43 trainer records, integrates with WordPress taxonomy system for business_type and training_audience classifications, handles comma-separated multi-value fields, automatically creates venues and organizers based on CSV flags, comprehensive error handling and progress tracking. Updated AJAX handler in class-hvac-geocoding-ajax.php for seamless integration with master trainer interface. Testing results: 43 rows processed, 43 profiles updated with enhanced data, proper taxonomy assignments, automatic venue/organizer creation, zero errors. System now provides complete professional profiles with contact information, certification tracking, business categorization, and event management integration. All components deployed to staging and verified working. - **Certificate Pages Template System Fix (2025-08-01)**: Resolved critical issue where certificate pages (/trainer/certificate-reports/, /trainer/generate-certificates/) were completely bypassing WordPress template system, showing only bare shortcode content without theme headers, navigation, or styling. Root cause: load_custom_templates() method in class-hvac-community-events.php was loading content-only templates from templates/certificates/ instead of proper page templates. Solution: Updated template paths to use templates/page-certificate-reports.php and templates/page-generate-certificates.php with full WordPress integration. Fixed duplicate breadcrumbs by adding aggressive Astra theme breadcrumb disable filters in HVAC_Astra_Integration class. Resolved missing navigation menu by removing problematic HVAC_NAV_RENDERED constant checks in page templates. Certificate pages now display with complete theme integration: proper headers/footers, single set of breadcrumbs, full navigation menu, and consistent styling. All fixes deployed to staging and verified working. - **MapGeo Certification Color Field Known Bug (2025-08-05)**: DOCUMENTED BUG: MapGeo plugin fails to render markers when certification_color field is mapped to "Fill Colour" in Other Map Fields configuration. Issue occurs despite all 53 trainer profiles having valid hex color values (#f19a42 for Champions, #5077bb for Trainers, #f0f7e8 for others). Root cause unknown - likely MapGeo plugin compatibility issue with custom post meta fields or specific hex color format requirements. Workaround: Remove certification_color from MapGeo Fill Colour mapping to restore marker visibility. Markers display correctly without color customization. Future investigation needed to determine MapGeo's expected color field format or alternative integration method for trainer certification-based marker styling. - **Welcome Popup System Implementation (2025-08-05)**: Implemented comprehensive Welcome Popup system for new HVAC trainer onboarding with 4-card interactive carousel showcasing platform features. System includes account status filtering (shows only to approved/active/inactive users, blocks pending/disabled), WCAG 2.1 AA accessibility compliance, Astra theme integration, and responsive design. Fixed critical overlapping navigation elements issue where dots/arrows covered footer content, making buttons unclickable. Final version (v1.0.6) features proper carousel height calculations (460px desktop, 380px tablet, 350px mobile), enhanced navigation spacing (20px 0 50px), and z-index layering (footer z-index: 10, elements z-index: 11). Includes dismissal management, WordPress security standards (nonce verification, capability checks), and comprehensive documentation. Deployed to staging and production-ready. Key files: includes/class-hvac-welcome-popup.php, assets/css/hvac-welcome-popup.css, assets/js/hvac-welcome-popup.js, docs/WELCOME-POPUP-SYSTEM.md. - **Training Leads and Navigation Menu Restructure (2025-08-05)**: Implemented comprehensive Training Leads system for HVAC trainers with contact form submission management. Created new "Training Leads" page (/trainer/training-leads/) with HVAC_Training_Leads class (includes/class-hvac-training-leads.php) and dedicated template (templates/page-trainer-training-leads.php). Features tabular display of contact submissions with Date, Name, Email, Phone, City, State/Province, and Message columns, AJAX-powered status updates, empty state messaging, and CTA for profile sharing. Restructured trainer navigation menu: renamed "Customize" to "Profile", moved "Logout" under "Profile" submenu, changed "Personal Profile" to "Trainer Profile", added "Training Leads" under Profile section. Updated help menu to display only question mark icon (no text) positioned to far right using CSS flexbox (margin-left: auto, order: 999). Enhanced documentation page with complete WordPress integration, proper navigation/breadcrumbs, and updated content reflecting current platform features including Training Leads system. All components deployed to staging with comprehensive E2E test coverage verification. Navigation changes improve UX by grouping related features under logical sections and providing quick access to new lead management functionality. - **Joe Medosch Account Updates (2025-08-05)**: Updated user joe@upskillhvac.com (ID: 20) display name from "Joe UpskillHVAC" to "Joe Medosch". Assigned Joe as author of key organizational assets: measureQuick headquarters venue (ID: 4869), both measureQuick organizer entries (IDs: 5429, 1667), and Upskill HVAC organizer (ID: 1647). All changes verified on staging server. Joe now properly credited in system as the lead contact for primary organizational entities, ensuring accurate attribution for training events and venue management. Updates maintain data integrity while reflecting correct organizational leadership structure. - **Registration Form Field Updates (2025-08-08)**: Successfully optimized three registration form fields per user requirements. Business Type changed from radio buttons to dropdown with 11 specific options (Association, Consultant, Service Company, Distributor or Supplier, Sales Representative, Educational Institution, Training Organization, Equipment Manufacturer, Other Manufacturer, Government, Other). Training Audience reduced to exactly 4 multi-select checkboxes ("Anyone (open to the public)", "Industry professionals", "Internal staff in my company", "Registered students/members of my org/institution"). Organization Headquarters changed from text inputs to dynamic country/state dropdowns with automatic state/province loading for US/Canada and text input fallback for other countries. All changes tested on staging and ready for production. CRITICAL: Monitoring infrastructure permanently disabled due to PHP segmentation faults - see warning section above. - **Safari Browser Compatibility Resolution (2025-08-08)**: ✅ **RESOLVED** - Critical Safari browser hanging issues completely resolved through comprehensive resource loading optimization system. Root cause identified as 35+ separate CSS file enqueue calls creating a resource loading cascade that overwhelmed Safari's rendering engine. Investigation revealed JavaScript syntax error in MapGeo integration and excessive component initialization cascade. Solution: Deployed Safari-specific resource loading bypass that detects Safari browsers and loads only 1 consolidated CSS file instead of 35+, automatically dequeues non-critical assets, implements intelligent browser detection with HVAC_Browser_Detection class, and maintains full functionality while preventing browser hangs. Additional fixes: removed CSS @import statements causing render blocking, optimized database queries in find-trainer template, implemented lazy component loading, reduced Astra theme hook priorities from 999 to 50, fixed JavaScript syntax error (dangling }) in MapGeo integration. Testing verified with Playwright WebKit engine - page loads successfully with complete functionality including interactive map, trainer cards, and navigation. Resource optimization reduced CSS files from 35+ to 3 core files. Production verification confirmed: **"THE PAGE FINALLY LOADS IN SAFARI!!!!!!!"** - User confirmation of successful resolution. Complete technical documentation in docs/SAFARI-COMPATIBILITY-INVESTIGATION.md. Status: Production-ready and user-verified working. - **Registration Form Production Deployment and Verification (2025-08-08)**: Successfully deployed updated registration form to production environment using `scripts/deploy.sh production`. Comprehensive Playwright E2E tests executed against production site (https://upskillhvac.com/trainer/registration/) with 100% pass rate. Test verification confirmed: all 40+ form fields functional with proper Business Type dropdown (11 options), Training Audience multi-select checkboxes (4 options), dynamic Organization Headquarters country/state dropdowns with automatic US/Canada state loading, file upload functionality for profile images and organization logos, complete form submission workflow, user registration with redirect to /registration-pending/. Database verification completed on production server: user account created (ID: 65), all user meta fields stored correctly (business_name, business_email, training_audience serialized array, first_name, last_name, application_details, business_type), organizer post created (ID: 6020 - "Test HVAC Training Company 1754663473108"), venue post created (ID: 6022 - "Test Training Center Dallas 1754663473108"). Registration system fully operational in production with complete end-to-end functionality verified through automated testing and manual database inspection. Test email: test.registration.1754663473108@example.com used for verification. - **Trainer Dashboard Template Refactoring (2025-08-11)**: Fixed critical dashboard and navigation issues. Root cause: hardcoded template override in `class-hvac-community-events.php` lines 804-806 forcing old shortcode-based template. Solution: removed hardcoded override, updated to use refactored `page-trainer-dashboard.php` template with proper WordPress integration. Fixed navigation menu rendering by removing conflicting `HVAC_NAV_RENDERED` constant checks in `class-hvac-menu-system.php` and page templates. Added missing `hvac-menu-system.css` file via git pull. Dashboard now displays correctly with working navigation across all trainer pages. Deployment script updated to automatically assign correct page template during deployment. - **Documentation Page Double Navigation Fix (2025-08-11)**: Resolved duplicate navigation bar issue on documentation page. Root cause: HVAC_Help_System class was rendering its own navigation (lines 223-231) via `[hvac_documentation]` shortcode while page template also rendered navigation. Solution: commented out duplicate navigation in `class-hvac-help-system.php`. Documentation page now uses comprehensive template (`page-trainer-documentation.php`) with table of contents sidebar, WordPress/Gutenberg integration, and single navigation instance. Help content provided via `HVAC_Documentation_Content` class with fallback to shortcode for empty pages. [... rest of the existing content remains unchanged ...]