How to add new translations and languages - NeosIT/active-directory-integration2 GitHub Wiki
Translations for other languages than English and German can be easily added. Please follow this guide.
Adding a new language
- Fork active-directory-integration2
- Create a new branch namend "translation-YOUR_LANGUAGE_KEY"
- Download Poedit
- Start Poedit and select "Create new translation (from PO/POT)"
- Select languages/ad-integration-2.0-de_DE.po
- Select the target language of the translation
- Happy translating
- Create a new pull request
Add new translation for existing strings
- Select Catalogue > Properties (or Alt + Enter)
- On tab Source path select all directories which contains strings (*classes*, *views*, *twig*)
- on tab Keywords from source code add
- __
- _e
- esc_html_
- Apply with OK
- Enable twig cache (active-directory-integration2\classes\Multisite\View\TwigContainer.php line 172)
- Visit every site containing ADI strings (Active Directory Integration > Configuration, Test authentication, Sync to AD, Sync to WordPress, Users, a user profile, Profile assignment, Profile options)
- Disable twig cache
- Push the button Update
- not-translated strings should appear