HTML5 <html> attributes xmlns, lang, xml:lang

I don't understand the HTML5 specifications for the lang and xml:lang attributes of the opening <html> tag. Scrolling up a bit, I understand that xmlns is a "talisman" (has no effect), but what about lang and xml:lang? Should they be used? If so, what should they be set to?

Answers


Everything I've seen and heard suggests that you should stick to

<!DOCTYPE html>
<html>
  <head>
    <meta charset='UTF-8'>

(or whatever character set you actually want). If you want a language associated with the page you can use the "lang" attribute on the <html> tag.

Since HTML5 is not XML, really, I personally would find it weird to use any xml: namespace stuff.


Need Your Help

Delete from uitableview + write to plist not working

ios objective-c uitableview nsmutablearray plist

i want to delete from uitableview and make it write to my plist. i'm pretty new to this objective-c iOS coding, so forgive me for mistakes

javascript not working textarea

javascript jquery

I'm trying to add things to a textarea. it's not working...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.