Skip Navigation

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

Problem: The latest version of Divi (June 6th 2019) seems to no longer has the search bar compatible with WPML (it always redirect you to the search page of the default language)

Solution: Please use this workaround in the meantime we release a new WPML update for it: Add the following hook: https://wpml.org/wpml-hook/wpml_add_language_form_field/ to your theme's header.php file in line 158 and 323.

0% of people find this useful.

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

Last updated by bilginK 2 years, 1 month ago.

Assigned support staff: Alejandro.

Author Posts
June 10, 2019 at 2:09 pm

bilginK

Hi, you will see the website has 3 languages. English, German and Turkish.

You search something on German or Turkish site, result page directs you English site.

Just please make a search on Turkish or German pages; you will see the bug.

I am using Divi and I think it happens after last update. So, are you still compatible with Divi?

June 10, 2019 at 3:00 pm
June 11, 2019 at 6:31 am #3992081

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

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

Hello,

Yesterday i sent your case to our developers and i'm waiting to hear from them.

I'll keep you updated.

June 11, 2019 at 11:06 am #3994505

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

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

Hello,

While we fix this on a permanent basis, i added a workaround to your site. i added the following hook: https://wpml.org/wpml-hook/wpml_add_language_form_field/ to your theme's header.php file in line 158 and 323 (there were 2 search forms defined there, the one you're using is the one with the code in line 323)

You can continue normally, we will ask the Divi Authors to add this fix on their end.

Regards.

June 12, 2019 at 8:01 am #4001439

bilginK

Hi Alejandra, thanks for the solution.

I don't use child theme, 'cause I don't edit php files. But now, you added a code to header.php I understand, and If I update Divi; it will be gone. Right? Then what do you recommend? And is it possible to let me know if Divi developers solve that problem?

Thank you

June 12, 2019 at 2:00 pm #4005011

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

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

We already sent everything to the Divi developers but it would be Excellent and even better if you could let divi developers know.

I think this will get fixed on the next Divi release, but if you can just create a child theme and copy the header.php file in there so you don't get that file overwritten.

Regards.

June 13, 2019 at 7:52 am #4010289

bilginK

My issue is resolved now. Thank you!