| 7:27 pm on Jul 2, 2009 (gmt 0)|
I think the use of <meta name=language content=EN> has been supplanted by the use of <html lang="en-US"> in HTML documents. A search for "country codes" will bring up sites that give country-codes and language codes, such as ES for Spanish and PT for Portuguese.
> How about the meta tag indicating revisit time length? <meta name=revisit-after content="2 days">
Absolutely worthless. This meta-tag was promulgated by a single, small Canadian directory's robot back in the mid-90's IIRC, and never had meaning to any other robot. A total waste of bytes, that one.
Robots visit when *they* want to, and not when we (Webmasters) tell them to -- and the <changefreq> tags in XML Sitemaps are only taken as a "hint," not as a command.
| 8:53 pm on Jul 2, 2009 (gmt 0)|
So this code has nothing to do with language
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
But adding a parameter to the <hmlt> initial tag does, right?
| 9:20 pm on Jul 2, 2009 (gmt 0)|
Right - the "EN" that appears in the doctype is the laguage of the doctype itself, not the language of the document.
| 10:33 pm on Jul 2, 2009 (gmt 0)|
I have some documents with this
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
How about that? Should I use
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en-US">
| 2:47 am on Jul 3, 2009 (gmt 0)|
For HTML documents with an XHTML doctype, use both the xml:lang and lang attributes. See [w3.org...]
| 3:13 am on Jul 3, 2009 (gmt 0)|
|Should I use <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en-US"> |
These articles from the W3C's internationalization area may help:
Internationalization Best Practices [w3.org]
Language tags in HTML and XML [w3.org]
| 3:31 am on Jul 3, 2009 (gmt 0)|
|I think the use of <meta name=language content=EN> has been supplanted by the use of <html lang="en-US"> |
Only if you want to restrict it to a regional variant, in that case US English.
lang="en" is perfectly valid and all-encompassing of every variety of English. You could restrict it by using Canada "en-ca", South Africa "en-za", Australia "en-au", New Zealand "en-nz", Trinidad and Tobago "en-tt", Great Britain "en-gb" etc. But what is the point, if you want all English speakers to be welcomed?
| 12:22 am on Jul 4, 2009 (gmt 0)|
Ouch, I just encoded to "en-US" and yes I want to welcome any english users.
But what does that really do? I mean, a page declared like "en-ca" will be only served in South Africa? What is the real incidence of using "en-US" instead "en" ?
| 12:24 am on Jul 4, 2009 (gmt 0)|
BTW did you notice that Webmasterworld doesn't use any "lang" in <html> tag? And seems to be fine...
| 12:40 am on Jul 4, 2009 (gmt 0)|
|But what does that really do? I mean, a page declared like "en-ca" will be only served in South Africa? What is the real incidence of using "en-US" instead "en"? |
The on-page language declaration can be used by the client (e.g browser) in any way that it likes. Having the lang set to en-CA (Canadian English) does not stop the page from being served to clients in the U.S. or the U.K, etc... And the page would have had to have been served for the client to have seen that declaration in the first place.
The locale specifications in the lang attribute are of most use when content-negotiation is used to serve different versions of a page to speakers of different language dialects, and the locale added to the lang attribute simply tells their browser which specific version you have served to them.
Note that the dialectical variations of English are fairly small compared to say, the differences between Mandarin and Cantonese Chinese. As a result, it's not very critical to specify the locale with English. Unless your content is specifically about some strong regional dialect like Cockney, you can get by with just specifying "lang=en" and "xml:lang=en" as recommended above.
| 3:36 pm on Jul 5, 2009 (gmt 0)|
Sorry I meant Canada and not South Africa. My content is not specific from any region and it's just plain english, however I used "en-US" instead just "en".
Should I worry in fixing that? What would the benefit be is what I don't have completely clear in my mind.
| 3:50 pm on Jul 5, 2009 (gmt 0)|
There's not a lot of testing data available about this - but the possibility is potentially better rankings and traffic from non-US countries.
You're in a good position to test a change if you want to try it, and that would add to our shared knowledge.
| 4:00 pm on Jul 5, 2009 (gmt 0)|
> worry about fixing that?
If it's U.S. English, then specify en-US. If it's British English or some other locale-based variant, then specify the correct locale. And if it's not specifically one or the other, or if you don't know specifically which it might be or do not provide different pages for different locales, then just specify "en."
Again, this is not a "critical" thing, but I do believe in "running a tight ship" and so I recommend that whatever attribute you provide, it should be accurate. You'll notice that the cause of many, many posts here about "weird" problems reported here at WebmasterWorld is failure to dot the i's and cross the t's -- URLs canonicalization problems, invalid robots.txt, incorrect DocTypes, invalid HTML, etc. It's best to make a good effort to get *everything* right if ranking and revenue are important to you.
| 6:16 pm on Jul 5, 2009 (gmt 0)|
|some strong regional dialect like Cockney |
Cor blimey Jim, you sayin' the geezers at IANA done a bleedin' meta tag special for us?
Would you Adam and Eve it! They've sure been keeping shtumm about it.
I better take a butchers at their black'n'white sharpish!
|British English or some other locale-based variant |
English, naturally enough, is the language of England.
"U.S. English" is either a locale-based variant or a collection of spelling mistakes.
| 11:07 pm on Jul 5, 2009 (gmt 0)|
> Cor blimey Jim, you sayin' the geezers at IANA done a bleedin' meta tag special for us?
Yeah, that's right, me old son... We're Misters, we are. Have 'em 'round for Rosy Lee on a fortnight. :)
BTW, that bit about "British English or some other locale-based variant" was intended to be lexically grouped/prioritized/parsed as "(U.S. English OR British English OR [any] other locale-based variant" where "some other locale" was meant as a way to avoid listing them all and as a synonymous phrase for "any other" and not as a derogative. Ah, what would I know, most of my old family's still back at the mines... ;)
> "U.S. English" is either a locale-based variant or a collection of spelling mistakes.
I like that, as I do another phrase from a well-know English statesman -- paraphrasing here: "Britain and America are two countries separated by a common language."