Skip to content Skip to sidebar Skip to footer

Is Valid HTML5 OK To Use Now?

I've been reading about HTML5 and would like to start using some of it, particularly datasets as I've found an interesting looking jQuery plugin that I can start using... http://ww

Solution 1:

I'd recommend checking out Dive Into HTML 5 and deciding for yourself if you think the tradeoffs are acceptable. So far as I've heard, there are no negative SEO implications for using HTML 5. I just ran the w3c validator on Dive Into HTML 5 and it automatically detected that it was HTML 5 and validated it, so I don't think that will be a concern, either.


Solution 2:

The answer is simple:

Not Yet! But soon.


Solution 3:

No it's not. It's not even possible to have valid HTML5 because the specification isn't ready yet.

You can however prepare your HTML4 for the change. The first step is to start using valid HTML4 strict and CSS.

There are some stable sections of the spec, like the <canvas> tag. The <video> tag is gaining ground and has already been implemented by WebKit and Gecko. More importantly, the <video> tag allows backwards compatibility to Flash for browsers that don't support it without using javascript.

The second step is to remove all requirements for proprietary (and free) plugins from your site, wherever it's possible, this includes Flash, Silverlight and JavaFx. In other words, always use the open standards when it's possible. Converting to HTML5 is a process and possible to do one step at a time. No need to rush things.


Solution 4:

With HTML 5 you're gonna run into a lot of problems, particularly on older version of Internet Explorer. Recently John Resig did a short talk (last 10 minutes) about the problems you're going to encounter.

  1. Attemping to use an unkown element causes it to be unstyled and generally malformed (inner contents escape) - However, there's a fix for that explained here HTML5 Shiv

  2. Even though, unknown elements still can't hold other unknown elements.

  3. Injecting unknown elements using innerHTML causes all sorts of weirdness to occur. It'll probably break your DOM.


Solution 5:

The most important thing is to test the parts of HTML5 you wish to use against the browsers you wish to support, and confirm there are no problems. You should especially check that your JS for accessing dataset data works in IE6 etc. You could also look at Microdata or RDFa to see if they offer a better fit for what you want to do. With the exception of new elements (which require a Javascript shiv to work in Internet Explorer) almost everything else is the same as HTML4/XHTML1, or should be ignored by unsupporting browsers.

Google doesn’t care what doctype you use, and adding data to datasets will be irrelevant to Google anyway (consider another method if you want to expose this data to search engines/users).

The W3 validator automatically detects the HTML5 doctype and uses the appropriate validator. Note that it can present a spurious error/warning regarding encoding—this is a known bug.

Regarding the answers, there’s a lot of FUD here:

  • using the HTML5 doctype != using new HTML5 elements
  • using HTML (rather than say XHTML) != poorly formed code
  • HTML5 != unsupported by IE6

Most of HTML5 is HTML4 with defined error handling. This means it’s perfectly ok to use most of HTML5 now, because you already are in HTML4/XHTML1. Of course parts of HTML5 are unsupported in IE6, but so are parts of HTML4. If you want to support IE6, don’t use those parts.


Post a Comment for "Is Valid HTML5 OK To Use Now?"