Welcome to WebmasterWorld Guest from 18.104.22.168
Forum Moderators: incrediBILL
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//NL" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
My site now validates at w3c as "Valid -//W3C//DTD XHTML 1.0 Transitional//NL", instead of "Valid XHTML 1.0 Transitional". Does that mean it's less-supported or invalid?
Or should I just ignore the difference and accept this as 'valid xhtml'?
Secondarily, language may also be indicated in a meta tag, but the lang attribute is supposed to override a meta tag language declaration, in case of a conflict.
<meta HTTP-EQUIV="Content-Language" Content="nl">
Language information is also sent by the server in the HTTP header.
Here's a W3C Reference [w3.org] about language on a web page. But, I can't find any W3C reference that recommends changing the DTD - so I wouldn't recommend it either.
Basically, the "EN" refers to the language of the DTD, not of the document itself. All W3C DTDs are written in English, so you should always use EN. If you have created your own DTD for your SGML documents, then it may be different (but you would be using SGML, not just HTML).
It is best to set the document language in the HTTP header before the page is served, or, failing that, to declare the language on the
element, either with the
attribute (for HTML) or the
attribute (for XHTML). You can also specify the language in a meta element if you aren't able to change the
element (if you're using a CMS with limited access to the markup, for example).