Mobile app version of vmapp.org
Login or Join
Murray432

: Can I have HTML link element both in headers and sitemap? For a multilingual site In my sitemap I am using: <url> <loc>http://www.xxxx/en</loc> <changefreq>daily</changefreq>

@Murray432

Posted in: #Headers #Html #Internationalization #Multilingual #Sitemap

For a multilingual site In my sitemap I am using:

<url>
<loc>http://www.xxxx/en</loc>
<changefreq>daily</changefreq>
<xhtml:link rel="alternate" hreflang="en" href="http://www.xxxx/en" />
<xhtml:link rel="alternate" hreflang="it" href="http://www.xxxx/it" />
<xhtml:link rel="alternate" hreflang="gr" href="http://www.xxxx/gr" />
</url>
<url>
<loc>http://www.xxxx/it</loc>
<changefreq>daily</changefreq>
<xhtml:link rel="alternate" hreflang="en" href="http://www.xxxx/en" />
<xhtml:link rel="alternate" hreflang="it" href="http://www.xxxx/it" />
<xhtml:link rel="alternate" hreflang="gr" href="http://www.xxxx/gr" />
</url>


Also in the <head> of the page I am using the <link> tag :



Two questions:


Do I need to just keep it in one place or it is better to have it in
both (I know that Google will support in under sitemap but what
about the other search engines?)
Do I need to do this for every page that has an alternative version
e.g:

<url>
<loc>http://www.xxxx/it/test.php</loc>
<changefreq>daily</changefreq>
<xhtml:link rel="alternate" hreflang="en" href="http://www.xxxx/en/test.php" />
<xhtml:link rel="alternate" hreflang="it" href="http://www.xxxx/it/test.php" />
<xhtml:link rel="alternate" hreflang="gr" href="http://www.xxxx/gr/test.php" />
</url>


or Google will automatically index the rest traversing down from
the main page?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Murray432

1 Comments

Sorted by latest first Latest Oldest Best

 

@Cofer257

I assume you mean you're using <link> elements in your HTML (as opposed to the <xhtml:link> for sitemaps).

Using the alternate links in the sitemap is beneficial for search engines only, whereas the links in the <head> of your web page could be used by browsers or other user-agents. I believe Opera used to make use of link elements but I don't know if that's still the case now they switched to the Chromium engine.

I would recommend using both anyway. There are likely to be other search engines that don't understand the xhtml:link elements in sitemaps, but do understand standard link elements.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme