Skip Navigation

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

Last updated by Raja Mohammed 4 years, 7 months ago.

Assisted by: Raja Mohammed.

Author Posts
July 17, 2019 at 8:46 am #4227675

Cara Mc Donough

Hi Raja,
Thanks again for helping me resolve the issue with displaying mixed EN & DE content on the main German Career page (hidden link).

Unfortunately, I have another issue to address. I have been in close contact with Yoast, but finally after days of trying to get it resolved, they came back this morning and asked that I contact WPML, as the issue is known problem and there is a workaround/temporary fix for the problem.

The issue: Yoast redirects for German pages are not redirecting to the main German career page…yes, the same Karriere page! I need to add that when I added the first German redirect (as listed below) I accidentally used “301 Permanent Redirect”. I have addressed this with Yoast and this does not seem to be the issue, although I can no longer access this redirect.

In any case, I followed the instructions in the following thread:
https://wpml.org/forums/topic/redirect-issue-with-yoast-seo/ and read your comments to another client in thread: https://wpml.org/forums/topic/yoast-redirections-with-urls-ending-by-a-are-broken-by-wpml/

I changed the wpseo-redirection.php file as recommended, but the problem has not been resolved.

After updating the PHP file to the server, I deleted all German redirects in Yoast. I continued to clear all caches for Theme, WPML and browser. Then I setup the temporary redirects again. Attached an overview of all “307 Temporary Redirects” that are setup in Yoast. The German redirects are still not working, but the English redirects are all working fine.

When setting up the temporary redirects for each of the 3 German pages, an error message was displayed, see attached. I selected “Save anyway” … as advised by Yoast. Confirmation was displayed for the redirect, again see attached.

Here are the pages in question and the results for each:

1. Redirect for:
hidden link
To:
hidden link

Result: the following page hidden link – EN Career Page is displayed!!!

2. Redirect for:
hidden link
To:
hidden link

Result: no redirect, German “Java Entwickler” page still showing

3. Redirect for:
hidden link
To:
hidden link

Result: no redirect, German “Software Entwickler” page still showing

Any idea, what I can do to fix this?

As always, appreciate your help.
Thanks,
Cara

yoast_307_temporary_redirects.jpg
error_saving_redirect.jpg
confirmation_redirect_added.jpg
July 17, 2019 at 3:51 pm #4231993

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hi there,

Welcome back,

I will be happy to help you better,

I can see a similar issue in our internal documents however I am unable to conclude whether it is the same, Is it possible for me to view the discussion of yours with Yoast team? if yes can you please pass on the link.

Try the below workaround solution on a test or staging environment, Highly recommended backup your site and database

Add this code to wp-content/plugins/sitepress-multilingual-cms/classes/url-handling/class-wpml-home-url-filter-context.php
after line 50:

private function seo_target() {
        return $this->debug_backtrace->is_class_function_in_call_stack( 'WPSEO_Redirect_Accessible_Validation', 'parse_target' );
    }

and at line 36 change this:

	|| $this->pagination_link();

to:

|| $this->pagination_link() || $this->seo_target();

Please use this code on a staging sit and make sure it fixes your issue If you need any assistance in creating a clone of your site I can help you migrate your site to our private server and test the code there.

Let me know the result

Kind regards
Raja

July 17, 2019 at 4:15 pm #4232093

Cara Mc Donough

Hi Raja,
Many thanks for your reply. Great to hear from you again.

Unfortunately, I do not have the possibility to create a clone of the site on a separate server nor on the current server we are using.

It would be really great if you could assist by migrating to your private server and testing before I try on our live server. May I ask, does a cost apply, if you migrate and test?

I can send you all the Yoast correspondence, but I will need to send a document...all email correspondence, although I really don't think it will help you any further, as you have the latest information. Also, with regards to cloning and being able to migrate the site, I would suggest setting up the Duplicator package again for you, then you can access direct in WP and download both installer and archive files....basically the same as last week.

Would that be ok?

I do need a secure message where I can send the document, links and new WP password, once you send I'll be in touch.

Thanks again,
Cara

July 18, 2019 at 4:54 am #4234957

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

I would prefer cloning your site to a private server so that it would be easy for us to verify the fix. Please refer to my previous private reply for details about migration.

Kind regards
Raja

July 18, 2019 at 8:30 am #4235999

Cara Mc Donough

Hi Raja,
Thanks again for both your replies.
The Migration has been completed successfully.

By the way, it wasn't possible to enter the Database User & Password - fields were not available for entry.

Looking forward to your feedback and hope you can help fix the problem.

Please keep me updated. Thanks,
Cara

July 18, 2019 at 12:57 pm #4238767

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

I have applied the fix in the clone site, Please check if your issue is resolved.

Let me know the results.

Kind regards
Raja

July 18, 2019 at 1:38 pm #4239223

Cara Mc Donough

Hi Raja,
I checked out the cloned site and entered part of the URL's that I had redirected, but I kept receiving an error "This site can’t be reached".

I went to the SEO->Redirects page and deleted the 3 German "307 Temporary Redirects" to see if I could setup the redirects again, this time without receiving an error message:
1. /de/java-entwickler/
2. /de/software-entwickler/
3. /de/business-analyst/

Under "Old URL" I entered the full URL: hidden link
and received the "relative" error message, see attached.

I selected "Cancel" and entered "/de/java-entwickler" and the same "301" error message was listed as before, see attached. I selected "Save anyway", which brings me back to square 1, how can I test the redirect, which URL should I enter?

Have you had success testing?

Thanks again,
Cara

error_saving_redirect.jpg
relative_redirect_error.jpg
July 19, 2019 at 11:47 am #4246127

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Thanks for your patience, After a few tests I am able to add the redirect in secondary language without any issues in the clone site, However, the redirect added in the secondary language is not working.

I would request you please install the latest version of Yoast premium to the sandbox site
One-Click Login:hidden link

WPML is already installed on the site please complete the configuration, Add a test page and translate it. This procedure will help in isolating the issue and once the issue is confirmed the same can be reported to our developers for a fix.

Please let me know once done

- Raja

July 19, 2019 at 1:14 pm #4246683

Cara Mc Donough

Hi Raja,
Just to let you know, I am out of the office until Wednesday next week.
I will contact you on Wednesday on my return and let you know what the result is after I have followed the steps as advised in your message.

Many thanks for your patience

July 22, 2019 at 10:39 am #4256193

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Sure, Thanks for the update,

July 25, 2019 at 7:26 am #4280025

Cara Mc Donough

Hi Raja,
Sorry for my late reply. Before I provide an update on the redirects, I wanted to share the following:

On my return to the office yesterday, I had urgent updates for all major pages of our website, plus I needed to add new pages. I discovered that the previous issue I had: https://wpml.org/forums/topic/remove-pages-from-translation-editor-manual-translation-required/ applies to all pages and the problem is a result of using “Classic Elements” in the Cornerstone builder, which are used on each page, because new alternative elements are not available, plus I am using the Essential Addons for Cornerstone plugin, which I use for Slider, Carousel functionality etc.

FYI, the fix which you shared in above thread fixes the problem, but this is extremely time-consuming. I have contacted Rad from Themeco customer support, who was involved at the very beginning of the issue and shared the issue about classic elements in their X-Theme and Cornerstone builder and the fix in order to try and get this resolved as soon as possible. I have asked them to contact somebody from WPML and hope there will be a fix available in the next release.

...................

OK, with regards to the Redirects issue ...
As requested, on the Sandbox site, I downloaded and installed Yoast SEO Premium version 11.7 Plugin. On completing the configuration of WPML, I downloaded, installed and activated Yoast SEO Multilingual Version 1.0.1
Please note: when completing the configuration of WPML, I noticed that certain settings are not available to change, so the settings are not the same as for the production site, e.g. “Menu language switcher”

Furthermore and FYI, under WPML->Support on the production site, the following Plugins and Versions are installed and active:
- WPML Multilingual CMS: 4.2.7.1
- WPML CMS Nav:1.5.2
- WPML String Translatio: 2.10.5.1
- WPML Sticky Links: 1.5.0
- WPML Translation Management: 2.8.6.2
- WPML Media: 2.5.2
- Gravity Forms Multilingual: 1.5.0
- Yoast SEO Multilingual: 1.0.1

I proceeded with adding a Test Page and translated to German as requested. Please note, I did not try to setup any Yoast redirects. I will leave that up to you, in case you want to test something else beforehand.

Over now to you. I hope we can get this resolved. Please keep me updated.

Thanks again for all your assistance,
Cara

July 26, 2019 at 4:07 pm #4291021

Cara Mc Donough

Hi Raja,
Just a quick note to let you know that I will be out of the office until Thursday next week (1st of August). Please make sure the ticket is not closed, if I don't respond. Thanks.

Hope you are making progress.

Thanks again for your assistance,
Cara

July 29, 2019 at 5:11 am #4297015

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

This seems to be a compatibility issue with YOAST redirect module, The redirect added from secondary language is being ignored. I have raised the issue to the second tier for a detailed investigation, I will keep you posted with any update.

Thanks and regards
Raja

August 1, 2019 at 6:58 am #4319141

Cara Mc Donough

Hi Raja,
Has any progress been made in finding a solution with your 2nd Tier colleagues?

Please keep me updated. Many thanks,
Cara

August 2, 2019 at 4:10 am #4326687

Raja Mohammed
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

The issue has been escalated to our developers for a fix, This is something that is being worked on, but unfortunately, I cannot provide a timeline for when it will be added.

Kind regards
Raja

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.