Перейти к содержимому Перейти к боковой панели

Помечено: 

Эта тема содержит 0 ответ, имеет 0 voices.

Последнее обновление: robertL-58 1 месяц назад.

При содействии: Itamar.

Автор Сообщения
19 ноября, 2025 в 3:57 пп #17592612

robertL-58

Background of the issue:
I am trying to replace the Twig code as I can see there is a post stating that Twig template support has been dropped, but there is still documentation on the site for Twig. I have replaced the Twig code with CSS so that the language switcher resembles the previous implementation using the Shortcode above. Here is the link to the documentation: https://wpml.org/documentation/support/wpml-coding-api/shortcodes/. The code I am working with is: [wpml_language_switcher] {% for code, language in languages %} {% if language.is_current %} {{ language.native_name }}: Currently Selected"{{ language.code|upper }} {% else %} {{ language.code|upper }} {% endif %} {% endfor %} [/wpml_language_switcher].

Symptoms:
The active language still remains targetable via focus, which is an issue for users accessing the site with a screen reader.

Questions:
Do you have an alternative method of implementation for your Twig Shortcode example?
Is there any solution you can provide for the issue with the active language being targetable via focus?