wegmeister / language-redirect
A Neos CMS package to handle language redirects based on the browser language.
Installs: 545
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 4
Forks: 1
Open Issues: 1
Type:neos-plugin
Requires
- php: >= 8.0
- neos/neos: >= 7.0.0
README
This package provides a simple language detection service for Neos CMS that will redirect users to the language version that fits their Accept-Language header best. It will only redirect if the uri path is empty (e.g. /).
Installation
Run the following command in your site package:
composer require --no-update wegmeister/language-redirect
Then run composer update
in your project root.
Configuration
Sometimes language codes are not configured the same as in Neos. Therefore you can configure a mapping in your Settings.yaml
:
Wegmeister: LanguageRedirect: # Add mappings for language codes if you use some different codes than the default ones. languageCodeOverrides: # For example, if you use "cz" instead of "cs" for Czech, you can add this mapping: cs: cz