Jump to content

HTML lang (for better SEO)


Axel Wers

Recommended Posts


ISO Language Codes

The HTML lang attribute can be used to declare the language of a Web page or a portion of a Web page. This is meant to assist search engines and browsers.

According to the W3C recommendation you should declare the primary language for each Web page with the lang attribute inside the <html> tag, like this:


<html lang="en">
...
</html>


globalTemplate

<!DOCTYPE html>
<html lang="en" 
.
.
.

Would better when this would be variable. In ACP every non-english administrator could set up html language. Without editing templates.

Link to comment
Share on other sites

Or base it on the locale set for the language pack.

That does not seem logical. The language pack is chosen by the website user, while the language is defined by the subforum.

A website can have multiple languages. For example: my website has social groups for each country. The language needs to be set differently per social group.

I also have different forum categories based on language. I have English, Dutch and German forums. The language meta needs to be set up differently per forum category.

It absolutely has no SEO relevance

My experience is different. It has relevance when you consider the various Google localizations. Even though my site has top ranking in google.com and google.co.uk , my Dutch and German forum content did not turn up in google.nl and google.de before I added lang meta code to those forums. After I added it, the content quickly appeared in these Google localizations.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Upcoming Events

    No upcoming events found
×
×
  • Create New...