HTML5 support

dfgfdgdfgdfg - November 9, 2008 - 19:59

Does anybody knows when Drupal will support HTML5? I am asking this as we have some screencast tutorials at our website and we may add more such video tutorials in the future. Currently, we are using Vimeo (Flash) for the videos, but native Ogg Theora using HTML5 would be much better of course.

As the browser usage of our visitors is very different from the global statistics (*), it will be no problem for us to switch to HTML5 when for example Internet Explorer does not yet supports that standard. Also, being able to switch our website to HTML5 would be an easy way for us to support open standards. That's why HTML5 support in Drupal would be very helpful to us.

(*) Roughly speaking our website browser usage stats are evolving like this:
* IE: dropping below 20%
* Firefox: about 60%
* Other browsers: about 20%

Probably not for a while.

gforce301 - November 9, 2008 - 20:25

Probably not for a while since neither HTML 5 nor XHTML 2 are official recommendations yet and it looks like it might be quite a while until they are. I can't speak for the core drupal development team, just my assessment.

Drupal will be able to do HTML 5

xmacinfo - November 9, 2008 - 21:10

It's not the right question to ask. You need to ask: "which browser supports HTML 5?".

The answer: none. HTML 5 is still in development. However, some browser are starting to implement some HTML 5 features. For example, Firefox 3.1 will support the HTML 5 < video > tag.

Drupal can generate HTML or XHTML, you'll just need to create the proper templates. So yes, you will probably be able to generate the proper code seen in your tutorial with Drupal, but only the browser mentioned in the tutorial will let you playback the content as intented.

I know that most of the

dfgfdgdfgdfg - November 9, 2008 - 21:37

I know that most of the current browsers do not supports HTML5, but as you also say, Firefox 3.1 will support the video tag (and probably more) of HTML5 which is the main reason why I would switch to HTML5 (dropping the dependency on Flash would be great).

So, when Firefox 3.1 is available, there will be at least 2 browsers with (some) HTML5 support. I guess Safari, Chrome and Konqueror will soon follow. When that happens, it would be really useful to me to be able to switch my Drupal site to HTML5, as all these browsers together account for about 80% of my visitors. For visitors who still use a browser with no support, I will add a link to the VLC website and the video file.

The advantage is that my website will not require Flash anymore.

PS: Opera and HTML5: http://dev.opera.com/articles/view/the-first-working-draft-of-html-5-is-...

"you'll just need to create the proper templates."

That's not enough I guess; how can I change for example the doctype of my html pages?

doctype

styro - November 9, 2008 - 22:18

That's not enough I guess; how can I change for example the doctype of my html pages?

That is defined at the top of your page.tpl.php template(s).

--
Anton

Simple DOCTYPE

xmacinfo - November 10, 2008 - 02:03

This is easy.

Take any Drupal theme, and like styro said, modify the page.tpl.php file. In that file, replace the doctype with this one:

<!DOCTYPE html>

html 5 and video

libre fan - August 27, 2009 - 14:38

it would be really useful to me to be able to switch my Drupal site to HTML5, as all these browsers together account for about 80% of my visitors. For visitors who still use a browser with no support, I will add a link to the VLC website and the video file.

Hear, hear! At last we can embed open format video in web sites in as simple a way as inserting a picture (img src and video src). So quick and clean.

Great idea to add a link to VLC too. 

That is also the wrong

amedee - December 15, 2008 - 13:16

That is also the wrong question to ask. You need to ask: "which browsers degrade gracefully with HTML5?".

The answer: (almost) all. Even with HTML5 specs in development, there is no reason not to use it. The basics of HTML5 are backwards compatible with HTML4, and all current browsers implement that.

page.tpl.php

mikeloyst - October 13, 2009 - 22:19

Would HTML5 support be as easy as modifying your .tpl.php files to render HTML5 tags?

PS what do you think adobe will do when the world no longer relies on flash? (i know they have other software to sell, but flash is such a huge part of the web)

You can definitely use HTML 5

nimbupani - December 17, 2009 - 03:56

You can definitely use HTML 5 in Drupal 6 themes now. I wrote about how to create a HTML 5 theme. I have not investigated how to make the forms use HTML 5 attributes though, I am sure it is not an easy task.

Well, I started and almost

f1vlad - December 21, 2009 - 15:18

Well, I started and almost finished converting my site to HTML5. I did hit a brickwall with the very same thing you mentioned; that is form input types. Haven't really come up with the solution yet.

As a sort of helper module I

alli.price - January 6, 2010 - 22:09

As a sort of helper module I created http://drupal.org/project/html5 which adds in support for older browsers which is effectively an implementation of some of remy sharp's solutions.

HTML5 Site

emwillhite - January 11, 2010 - 04:47

I just finished up my own site in HTML5/Drupal6, so it's definitely do-able. However, just as with browsers, I imagine implementation of all the new elements, form inputs, etc. will take quite some time.

evanwillhite.com

Your Site

CinemaSaville - February 19, 2010 - 00:38

Great job on the site, Evan. Really a nice Drupal site. You have a flair for design. Congratulations, and I look forward to your future creations. I'm going to try to implement the audio and video tags for HTML5 on my site so I don't have to rely on flash, but it's a little daunting at the moment. Thanks for the inspiration.

Jeremy
http://CinemaSaville.com

 
 

Drupal is a registered trademark of Dries Buytaert.