Skip Navigation

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

Problem:
If you're experiencing an issue where the language name in your dropdown menu is displayed twice, this may be due to an incorrect attribute assignment in the theme or addon plugin you are using.

Solution:
We recommend the following steps:
1. Try using the standard Menu widget of Elementor instead of the theme-specific Header Menu widget.
2. If you prefer to keep using the theme-specific widget, you may need to modify the code in the file

/wp-content/plugins/ai-max-plus/modules/menu/walker/frontend-menu-walker.php

on line 157. Replace the existing code with:

$link_before = $args->link_before;

Please ensure you backup your database and website before making any changes.

It's important to note that the theme AI-Max is not listed in our compatible themes directory. We suggest reaching out to the theme author and asking them to participate in our Go Global program, where our Compatibility developers can assist in making the product compatible with WPML.

If this solution doesn't seem relevant to your situation, please open a new support ticket with us.

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 contains 6 replies, has 4 voices.

Last updated by Andrés 5 months, 3 weeks ago.

Assisted by: Long Nguyen.

Author Posts
January 22, 2024 at 8:30 am #15209742

denizS-6

hidden link this is my website i made a dropdown language in menu but it show two time of the name of language please visit the website and check the issue

January 22, 2024 at 9:01 am #15209965

Bruno Kos
Supporter

Languages: English (English ) German (Deutsch ) French (Français )

Timezone: Europe/Zagreb (GMT+02:00)

Let us know how the theme test went.

January 22, 2024 at 4:14 pm #15212802

denizS-6

i tried my website must need that theme to run. it not work same problem

January 23, 2024 at 7:30 am #15214212

Long Nguyen
Supporter

Languages: English (English )

Timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Hi Deniz,

Thank you for contacting WPML support, I'd be happy to help you with this issue.

I would like to request temporary access (wp-admin and FTP) to your site to take a better look at the issue. It would be better to have a testing site where the issue is replicated. Your next reply is set to private to share the info.

❌ IMPORTANT: Please backup your database and website before proceeding ❌
You can use this plugin to create the backup: https://wordpress.org/plugins/duplicator/
✙ I would need your permission to de-activate and re-activate Plugins and the Theme to change configurations on the site if needed. This is also a reason the backup is critical.

Look forward to your reply.
Thanks

January 24, 2024 at 8:52 am #15220315

Long Nguyen
Supporter

Languages: English (English )

Timezone: Asia/Ho_Chi_Minh (GMT+07:00)

Hi,

I see the issue. It happens when you use the Elementor widget Header Menu from the theme AI-Max and its addon plugin AI Max Plus.
There is a code that modify the default menu of WordPress in the file /wp-content/plugins/ai-max-plus/modules/menu/walker/frontend-menu-walker.php line 157.

$link_before = str_replace('%1$s', $title, $args->link_before);

To fix the issue, I suggest you try:

1. Use the standard Menu widget of Elementor.

2. Or replace the code above with this one:

$link_before = $args->link_before;

❌ IMPORTANT: Please backup your database and website before proceeding ❌

The theme AI-Max is not available in our list of compatible themes https://wpml.org/theme/
I suggest you contact the theme author and ask them to join our Go Global program where our Compatibility developers will help them to make their product compatible with WPML.
https://wpml.org/documentation/support/go-global-program/

Look forward to your reply.
Thanks

January 24, 2024 at 9:20 am #15220581

denizS-6

$link_before = $args->link_before; i use this and it solve now

April 3, 2024 at 12:44 pm #15478463

Andrés
Supporter

Languages: English (English ) Spanish (Español ) French (Français )

Timezone: Europe/Paris (GMT+02:00)

Hello there,
Just to let you know that this issue should have been solved with WPML 4.6.10.
Regards

denizS-6 confirmed that the issue was resolved on 2024-01-24 09:20:23.
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.