Skip to content Skip to sidebar

This thread is resolved. Here is a description of the problem and solution.

Problem:
You are trying to create a language switcher for the header menu on your website, but the source code of the language switcher appears instead of the switcher itself. This issue persists regardless of the parameters you configure for the language switcher, while the footer language switcher displays correctly.
Solution:
We recommend checking if the issue still occurs when using a default theme, as your current theme might be filtering out the dropdown item, preventing the language switcher from being displayed. If the language switcher works correctly with the default theme, consider using a language switcher outside your menu. You might find using a shortcode, widget, or the floating language switcher helpful. For more details on these alternatives, please visit: Custom Language Switcher.

If this solution does not apply to your case, or if it seems 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 you still need assistance, 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.

Tagged: 

This topic contains 1 replies, has 0 voices.

Last updated by davidK-140 1 day, 5 hours ago.

Assisted by: Andrey.

Author Posts
August 6, 2025 at 3:53 pm #17300337

davidK-140

Background of the issue:
I am trying to create a language switcher for the header menu on my website. However, the source code of the language switcher appears instead of the switcher itself, which is not being rendered. This issue occurs regardless of the parameters I configure for the language switcher. The footer language switcher displays correctly and works as expected. Here is the link to the page where the issue can be seen: hidden link. I am also attaching links to screenshots where the issue can be seen: hidden link, hidden link.

Symptoms:
The source code of the language switcher is displayed in the header menu instead of the switcher itself.

Questions:
Why is the source code of the language switcher appearing in the header menu instead of the switcher itself?
How can I fix the issue so that the language switcher is rendered correctly in the header menu?

August 6, 2025 at 7:12 pm #17300726

Andrey
WPML Supporter since 06/2013

Languages: English (English ) Russian (Русский )

Timezone: Europe/Kyiv (GMT+03:00)

Thank you for contacting WPML support.

It's possible that your current theme filters out the dropdown item, preventing the language switcher from showing. Have you checked if the issue still occurs when using a default theme?

If everything works fine with the default theme, you may want to consider using a language switcher somewhere outside your menu, maybe using the shortcode, widget, or perhaps the floating language switcher will be good alternative: https://wpml.org/documentation/getting-started-guide/language-setup/language-switcher-options/custom-language-switcher/#bonus-vertical-floating-language-switcher

August 9, 2025 at 2:44 pm #17306929

davidK-140

Hello,

awesome and fast support. We solved it as u recommend. Thank you!