This thread is resolved. Here is a description of the problem and solution.
Problem:
The client wanted to add a language switcher to the header of their website, specifically in a mobile view, to make it appear just with flags and a dropdown the size of the flags, similar to the WPML site.
Solution:
We recommended two approaches:
1. Add a language switcher in a custom location using PHP by inserting the following code:
do_action('wpml_add_language_selector')
. We advised contacting the theme developer for guidance on where to place this code within the theme files. More information on this method can be found here: Adding Language Switchers using PHP.
2. If the client is using Elementor, they can add a shortcode directly in the header using the Elementor templates. The shortcode to use is:
[wpml_language_selector_widget]
. After adding the shortcode, adjustments can be made with CSS to style the switcher similarly to the WPML site.
If these solutions do not resolve your issue or if they seem outdated, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If further assistance is needed, please open a new support ticket at WPML support forum.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
This topic is split from https://wpml.org/forums/topic/automatic-translations-arent-showing/
This topic contains 1 reply, has 2 voices.
Last updated by Bobby 1 month, 3 weeks ago.
Assisted by: Bobby.
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.