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.

No supporters are available to work today on this forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

This topic contains 7 replies, has 2 voices.

Last updated by Dražen Duvnjak 1 month, 1 week ago.

Assigned support staff: Dražen Duvnjak.

Author Posts
January 12, 2021 at 12:42 pm #7825123

maximilianM-4

Tell us what you are trying to do?

I have the blog hidden link and the new domain hidden link. I submitted both to Search Console for indexing via a sitemap from Yoast. However, the English version is not indexed for me.

The Search Console is telling me "Redirect Error" but its linked to the .net Page.

Is there any documentation that you are following?

I checked already all different Forum / FAQ but I didn't found the Solution.

Is there a similar example that we can see?

No

What is the link to your site?

hidden link (German)
hidden link (English)

January 13, 2021 at 10:49 am #7833435

Dražen Duvnjak
Supporter

Languages: English (English )

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

Hello,

thanks for sharing info about your issue, I will be glad to help you out.

You mentioned:

However, the English version is not indexed for me.

If I check Google for English URL, it seems it is indexed fine, image attached.

I have also checked both sitemaps links and they same fine to me:

- hidden link
- hidden link

If you try to visit hidden link you are redirected to the .de domain, which should not be the case. Probably that is the issue Google is reporting to you. While hidden link works fine.

If I check the redirect rule it seems it was done by the WP Rocket plugin, image attached.

Can you please check your website hosting and WP Rocket / Yoast SEO plugin settings for redirect rules and make sure to remove the mentioned redirect rule.

Please let me know how it goes and don't hesitate to ask if you find any problem along the way or have doubts or questions about the steps mentioned above, I'll do my best to help you in the best way possible.

Regards,
Drazen

January 13, 2021 at 11:01 am #7833533

maximilianM-4

Hi Drazen,

thanks a lot for your reply.

I just checked my htaccess file if there is something while redirects to the .de domain but I could not find anything.

Attached the file:

# BEGIN WP Rocket v3.8.1
# Use UTF-8 encoding for anything served text/plain or text/html
AddDefaultCharset UTF-8
# Force UTF-8 for a number of file formats
<IfModule mod_mime.c>
AddCharset UTF-8 .atom .css .js .json .rss .vtt .xml
</IfModule>
# FileETag None is not enough for every server.
<IfModule mod_headers.c>
Header unset ETag
</IfModule>
# Since we’re sending far-future expires, we don’t need ETags for static content.
# developer.yahoo.com/performance/rules.html#etags
FileETag None
<IfModule mod_alias.c>
<FilesMatch "\.(html|htm|rtf|rtx|txt|xsd|xsl|xml)$">
<IfModule mod_headers.c>
Header set X-Powered-By "WP Rocket/3.8.1"
Header unset Pragma
Header append Cache-Control "public"
Header unset Last-Modified
</IfModule>
</FilesMatch>
<FilesMatch "\.(css|htc|js|asf|asx|wax|wmv|wmx|avi|bmp|class|divx|doc|docx|eot|exe|gif|gz|gzip|ico|jpg|jpeg|jpe|json|mdb|mid|midi|mov|qt|mp3|m4a|mp4|m4v|mpeg|mpg|mpe|mpp|otf|odb|odc|odf|odg|odp|ods|odt|ogg|pdf|png|pot|pps|ppt|pptx|ra|ram|svg|svgz|swf|tar|tif|tiff|ttf|ttc|wav|wma|wri|xla|xls|xlsx|xlt|xlw|zip)$">
<IfModule mod_headers.c>
Header unset Pragma
Header append Cache-Control "public"
</IfModule>
</FilesMatch>
</IfModule>
# Expires headers (for better cache control)
<IfModule mod_expires.c>
ExpiresActive on
ExpiresDefault "access plus 1 month"
# cache.appcache needs re-requests in FF 3.6 (thanks Remy ~Introducing HTML5)
ExpiresByType text/cache-manifest "access plus 0 seconds"
# Your document html
ExpiresByType text/html "access plus 0 seconds"
# Data
ExpiresByType text/xml "access plus 0 seconds"
ExpiresByType application/xml "access plus 0 seconds"
ExpiresByType application/json "access plus 0 seconds"
# Feed
ExpiresByType application/rss+xml "access plus 1 hour"
ExpiresByType application/atom+xml "access plus 1 hour"
# Favicon (cannot be renamed)
ExpiresByType image/x-icon "access plus 1 week"
# Media: images, video, audio
ExpiresByType image/gif "access plus 4 months"
ExpiresByType image/png "access plus 4 months"
ExpiresByType image/jpeg "access plus 4 months"
ExpiresByType image/webp "access plus 4 months"
ExpiresByType video/ogg "access plus 4 months"
ExpiresByType audio/ogg "access plus 4 months"
ExpiresByType video/mp4 "access plus 4 months"
ExpiresByType video/webm "access plus 4 months"
# HTC files (css3pie)
ExpiresByType text/x-component "access plus 1 month"
# Webfonts
ExpiresByType font/ttf "access plus 4 months"
ExpiresByType font/otf "access plus 4 months"
ExpiresByType font/woff "access plus 4 months"
ExpiresByType font/woff2 "access plus 4 months"
ExpiresByType image/svg+xml "access plus 1 month"
ExpiresByType application/vnd.ms-fontobject "access plus 1 month"
# CSS and JavaScript
ExpiresByType text/css "access plus 1 year"
ExpiresByType application/javascript "access plus 1 year"
</IfModule>
# Gzip compression
<IfModule mod_deflate.c>
# Active compression
SetOutputFilter DEFLATE
# Force deflate for mangled headers
<IfModule mod_setenvif.c>
<IfModule mod_headers.c>
SetEnvIfNoCase ^(Accept-EncodXng|X-cept-Encoding|X{15}|~{15}|-{15})$ ^((gzip|deflate)\s*,?\s*)+|[X~-]{4,13}$ HAVE_Accept-Encoding
RequestHeader append Accept-Encoding "gzip,deflate" env=HAVE_Accept-Encoding
# Don’t compress images and other uncompressible content
SetEnvIfNoCase Request_URI \
\.(?:gif|jpe?g|png|rar|zip|exe|flv|mov|wma|mp3|avi|swf|mp?g|mp4|webm|webp|pdf)$ no-gzip dont-vary
</IfModule>
</IfModule>
# Compress all output labeled with one of the following MIME-types
<IfModule mod_filter.c>
AddOutputFilterByType DEFLATE application/atom+xml \
application/javascript \
application/json \
application/rss+xml \
application/vnd.ms-fontobject \
application/x-font-ttf \
application/xhtml+xml \
application/xml \
font/opentype \
image/svg+xml \
image/x-icon \
text/css \
text/html \
text/plain \
text/x-component \
text/xml
</IfModule>
<IfModule mod_headers.c>
Header append Vary: Accept-Encoding
</IfModule>
</IfModule>
<IfModule mod_mime.c>
AddType text/html .html_gzip
AddEncoding gzip .html_gzip
</IfModule>
<IfModule mod_setenvif.c>
SetEnvIfNoCase Request_URI \.html_gzip$ no-gzip
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{HTTPS} on [OR]
RewriteCond %{SERVER_PORT} ^443$ [OR]
RewriteCond %{HTTP:X-Forwarded-Proto} https
RewriteRule .* - [E=WPR_SSL:-https]
RewriteCond %{HTTP:Accept-Encoding} gzip
RewriteRule .* - [E=WPR_ENC:_gzip]
RewriteCond %{REQUEST_METHOD} GET
RewriteCond %{QUERY_STRING} =""
RewriteCond %{HTTP:Cookie} !(wordpress_logged_in_.+|wp-postpass_|wptouch_switch_toggle|comment_author_|comment_author_email_) [NC]
RewriteCond %{REQUEST_URI} !^(/(.+/)?feed/?.+/?|/(?:.+/)?embed/|/(index\.php/)?wp\-json(/.*|$))$ [NC]
RewriteCond %{HTTP_USER_AGENT} !^(facebookexternalhit).* [NC]
RewriteCond "%{DOCUMENT_ROOT}/wp-content/cache/wp-rocket/%{HTTP_HOST}%{REQUEST_URI}/index%{ENV:WPR_SSL}%{ENV:WPR_WEBP}.html%{ENV:WPR_ENC}" -f
RewriteRule .* "/wp-content/cache/wp-rocket/%{HTTP_HOST}%{REQUEST_URI}/index%{ENV:WPR_SSL}%{ENV:WPR_WEBP}.html%{ENV:WPR_ENC}" [L]
</IfModule>
# END WP Rocket
# BEGIN WordPress
# Die Anweisungen (Zeilen) zwischen „BEGIN WordPress“ und „END WordPress“ sind
# dynamisch generiert und sollten nur über WordPress-Filter geändert werden.
# Alle Änderungen an den Anweisungen zwischen diesen Markierungen werden überschrieben.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
# BEGIN ShortPixelWebp
# Die Anweisungen (Zeilen) zwischen „BEGIN ShortPixelWebp“ und „END ShortPixelWebp“ sind
# dynamisch generiert und sollten nur über WordPress-Filter geändert werden.
# Alle Änderungen an den Anweisungen zwischen diesen Markierungen werden überschrieben.
# END ShortPixelWebp

In the Yoast and WP Rocket files I was not able to find anything with a rewrite rule (settings). The Domain points in the hosting to the same folder like the .de Domain.

Would be great if you could help me here.

January 13, 2021 at 2:01 pm #7835717

Dražen Duvnjak
Supporter

Languages: English (English )

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

Hello,

thanks for getting back.

It seems the issue happens only with the www version, without it works fine, not redirected. It could be caused by one of the rule in htaccess.

I can suggest you try next:

Please make a backup before proceeding.

1) Please change your theme to the WP default theme and disable ALL plugins. Check if the issue happens?

This way I can see if the issue connected with WPML plugins and if is happening also when WPML disabled and if it is coming from some 3rd party plugin settings.

2) Backup your htaccess and create a new one containing only default WordPress rules as described here: https://wordpress.org/support/article/htaccess/

Check if the issue happens.

3) Enable only WPML plugins and check if the issue happens.

4) Enable plugins 1 by 1 to see if the issue appears again.

Let me know how it goes and if you still have issues.

Kind regards,
Drazen

January 13, 2021 at 7:09 pm #7838469

maximilianM-4

Hi Drazen,

thanks for the recommendation.

I already tried - but I was not possible to "delete" this error.

Also the options which WPRocket gives are not showing any options.

Any other recommendations?

Best

Max

January 14, 2021 at 7:54 am #7841183

Dražen Duvnjak
Supporter

Languages: English (English )

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

Hello Max,

thanks for getting back.

I am not sure what is the result for each test I suggested, but I would assume the issue is still there.

So when you use the WP default theme, disable ALL plugins, clear all cache, and use only default htaccess rules, the issue is still there?

If yes, then the redirect is coming from somewhere else, not WordPress, and the best would be to contact your hosting support to check server and domain settings and help you out with this.

Let me know how it goes and if there is anything else I can do for you.

Kind regards,
Drazen

January 15, 2021 at 10:29 pm #7856411

maximilianM-4

Good Evening Drazen,

I was checking some solutions and i deactivated an deleted WP Rocket now the Redirect is gone.

But its not the solution for my problem because I need WP Rocket.

I already get in touch with WP Rocket to find a Solution but its still unclear how the 301 gets into that.

What would you recommend to fix that issue?

Best

Max

January 18, 2021 at 7:50 am #7865971

Dražen Duvnjak
Supporter

Languages: English (English )

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

Hello Max,

thanks for getting back.

I agree the solution is not to delete WP Rocket, but glad to hear you found the cause of the issue.

I suggest next, deactivate WPML plugins for a moment and check if the redirect rule still exists. That way we can check if this happens without WPML also or the issue is caused when WP Rocket and WPML both activated.

If it happens also without WPML then the cause is not related to WPML and the problem is coming solely from WP Rocket. I suggest to share that info with WP Rocket support and I am sure they will help and find a solution for your problem.

I see they have some similar problem explained on their website that you might want to check, but I suggest first confirming with plugin support:

- hidden link

If the issue happens when only WPML and WP Rocket activated, let me know and I will check this issue further.

Let me know how it goes.

Kind regards,
Drazen