-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Description
It would be nice if the generated translation_id would be used to generate alternate link in <head> section of a post.
Reason behind the proposal
Help search engines to serve the most appropriate (language) content.
Expected behaviour
Write an alternate_lang_link tag in the <head> section of a post layout:
<!DOCTYPE html>
<head>
<meta charset="utf-8">
{% alternate_lang_link %}
...the tag should search all posts which shares the same translation_id and than for each post it should generate a list of strings for each language like:
<link rel="alternate" hreflang="<POST_LANG>" href="<POST_URL>" />
If an it, en, de, multilingual site had posts at URLs like:
- http://www.my-multilingual-site.com/it/blog/post-favoloso
- http://www.my-multilingual-site.com/en/blog/awsome-post
- http://www.my-multilingual-site.com/de/blog/geweldig-bericht
the generated posts should all contains:
<!DOCTYPE html>
<head>
<meta charset="utf-8">
<link rel="alternate" hreflang="it" href="http://www.my-multilingual-site.com/it/blog/post-favoloso" />
<link rel="alternate" hreflang="en" href="http://www.my-multilingual-site.com/en/blog/awsome-post" />
<link rel="alternate" hreflang="de" href="http://www.my-multilingual-site.com/de/blog/geweldig-bericht" />
...Thank you very much in advance for your help,
Tarin
Metadata
Metadata
Assignees
Labels
No labels