This plugin adds Polylang support for WordPress Customizer.
- Language switcher in Customizer.
- Localized theme_mods and options for both default and custom made Customizer values.
- Enable/disable forcing “The language is set from content” setting in
Language
>Settings
>URL modifications
- Polylang must be installed and activated.
- Languages must be set in Admin > Languages.
- If you have a static front page:
- Create a front page per each language.
- Select the front page in Admin > Settings > Reading per language.
- Expect customizer to use setting type =
theme_mod
(default) as in:
$wp_customize->add_setting( 'setting_id', [ 'type' => 'theme_mod', ] );
This plugin can be installed directly into your plugins folder "as-is"
or:
- go to Plugins > Add new and type in Search
Add Polylang support for Customizer
and click Install and then Activate buttons. - if you go to Admin panel > Plugins > Add new > Upload Plugin and select the archive containing this plugin.
It's safe to activate the plugin at this point. Because the plugin just injects some functionality - there will be no plugin menus or settings to play with. License
This plugin is licensed under the GPL v2 or later; however, if you opt to use third-party code that is not compatible with v2, then you may need to switch to using code that is GPL v3 compatible.
For reference, here's a discussion that covers the Apache 2.0 License used by Bootstrap.
Original solution made by @soderlind is available here. Share some love! This is WordPress plugin version of his solution.