Skip Navigation

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

Problem:
The client wants to add a space between the native language name and the language name in the current language in the WPML language switcher.
Solution:
We recommend adding custom CSS to create the desired space. You can do this by navigating to WPML → Languages → Language switcher options and inserting the following CSS in the Additional CSS text area:

.wpml-ls-display {
margin-left: 5px;
}

If this solution does not work for you, or if it seems outdated or irrelevant to your case, please do not hesitate to open a new support ticket. We also highly recommend checking related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins.

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 reply, has 2 voices.

Last updated by Mohamed Sayed 1 year, 4 months ago.

Assisted by: Mohamed Sayed.

Author Posts
February 18, 2024 at 6:23 pm #15315384

A.S.

Hello,

I've got a minor but intractable issue.

I'd like the language switcher in my menu to display the foreign language like this:
Español (Spanish)

So first Native language name, then (Language name in the current language).

And the language switcher lets me do that easily. Very good. But the result is this:
Español(Spanish)

... The problem is that I would like a space between the two! How do I do this?

Thank you in advance for your help.

February 18, 2024 at 9:52 pm #15315587

Mohamed Sayed

Hi,
Thanks for contacting WPML support.

This can be fixed with custom CSS, please go to WPML → Languages → Language switcher options and add the following CSS in the Additional CSS text area:

.wpml-ls-display {
    margin-left: 5px;
}

Let me know please if that helps.

Kind regards,
Mohamed

Screenshot_671.png
February 19, 2024 at 7:12 am #15316039

A.S.

Hello Mohamed,

It worked! Thank you very much.

Kind regards,

A.S.