?
avatar mediafish
mediafish
3 Apr 2017

Steps to reproduce the issue

I have a website available in 3 languages: Spanish (default), English & German.
If you check the source code of the Spanish version (as an example but behaviour is the same on all) homepage you can see the alternate hreflang for: Spanish, English and German but:

Expected result

I expect on the Spanish Version to show only the equivalent pages in their languages so on the Spanish version it should show:

	<link href="http://www.mediafish.es/de/" rel="alternate" hreflang="de" />
	<link href="http://www.mediafish.es/en/" rel="alternate" hreflang="en" />

Actual result

It also shows the Spanish Version as alternate hreflang which is not correct as we are already on the Spanish version so it should only link to the alternate versions English & German...

	<link href="http://www.mediafish.es/de/" rel="alternate" hreflang="de" />
	<link href="http://www.mediafish.es/" rel="alternate" hreflang="es" />
	<link href="http://www.mediafish.es/en/" rel="alternate" hreflang="en" />

System information (as much as possible)

Joomla 3.6.5

Additional comments

avatar mediafish mediafish - open - 3 Apr 2017
avatar joomla-cms-bot joomla-cms-bot - change - 3 Apr 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 3 Apr 2017
avatar joomla-cms-bot joomla-cms-bot - edited - 3 Apr 2017
avatar franz-wohlkoenig franz-wohlkoenig - change - 3 Apr 2017
Category Multilanguage
avatar franz-wohlkoenig franz-wohlkoenig - change - 3 Apr 2017
Build staging 3.6.5
avatar SharkyKZ
SharkyKZ - comment - 3 Apr 2017

This behavior is correct as per Google guidelines:

If you have multiple language versions of a URL, each language page should identify different language versions, including itself. For example, if your site provides content in French, English, and Spanish, the Spanish version must include a rel="alternate" hreflang="x" link for itself in addition to links to the French and English versions. Similarly, the English and French versions must each include the same references to the French, English, and Spanish versions.
https://support.google.com/webmasters/answer/189077?hl=en

avatar Bakual
Bakual - comment - 3 Apr 2017

Closing as expected behavior.

avatar Bakual Bakual - change - 3 Apr 2017
Status New Closed
Closed_Date 0000-00-00 00:00:00 2017-04-03 13:14:22
Closed_By Bakual
avatar Bakual Bakual - close - 3 Apr 2017
avatar mediafish
mediafish - comment - 3 Apr 2017

well ok but they write:

...the Spanish version must include a rel="alternate" hreflang="x" link...

why do they use X and not es?

avatar franz-wohlkoenig franz-wohlkoenig - change - 3 Apr 2017
Status Closed Expected Behaviour
avatar Bakual
Bakual - comment - 3 Apr 2017

why do they use hreflang="x" and not hreflang="es" if they talk about the Spanish version?

It's a placeholder for the language, like back in school when you had algebra ?
In the examples on the page it's clear that "x" isn't a valid value.

avatar mediafish
mediafish - comment - 7 Apr 2017

Well ok you know that because of your experience and thanks for pointing that out :-)

...but if you start talking about algebra; at school we only used placeholders if we were talking about unknown values - but here the value is Spain so no need for "x "but "es" ;-)

Add a Comment

Login with GitHub to post a comment