3 Commits

Author SHA1 Message Date
434334c810 Fix SimpleTemplate TypeError with array handling
- Fix htmlspecialchars() receiving arrays instead of strings
- Add proper type checking for string, array, and other types
- Convert arrays to JSON for safe template rendering
- Remove unused German and French language files
2025-11-22 21:32:38 +01:00
25769cef24 Implement dynamic language system with automatic detection
- Add getAvailableLanguages() method to scan lang directory automatically
- Add getNativeLanguageName() method for proper language display names
- Enhance SimpleTemplate engine to support array iteration with {{#array}} syntax
- Update header template to use dynamic language dropdown with native names
- Add German (de.php) and French (fr.php) language files as examples
- Fix search input text color to use black text for better visibility
- Languages now appear automatically when added to engine/lang/ without code changes
2025-11-22 21:06:50 +01:00
a2b7fcb1a8 ## Complete Multi-language System & Navigation Enhancement
### Features Added:
- **Multi-language Support**: Dutch/English with URL-based switching (?lang=nl|en)
- **Theme Customization**: Configurable header/navigation colors via config.json
- **Navigation Improvements**: Active states, dropdown chevron icons, visual distinction
- **Mobile Responsive**: Separate desktop/mobile search layouts
- **Template System**: Fixed rendering pipeline for all partials

### Technical Fixes:
- Fixed language file path (engine/lang/ vs engine/core/class/../lang/)
- Added template data rendering to layout template
- Implemented navigation active state for default/home page
- Added chevron icons to dropdown folders for visual distinction
- Removed hardcoded navigation opacity class for theme colors

### Files Modified:
- config.json: Added theme and language configuration
- engine/core/class/CodePressCMS.php: Multi-language and navigation logic
- engine/templates/: Enhanced header, footer, navigation, layout
- engine/lang/: Dutch and English translation files
- public/assets/css/mobile.css: Mobile responsive fixes

### Result:
Fully functional multi-language CMS with proper navigation states and theme customization.
2025-11-22 15:29:47 +01:00