Fai 0


I'd like to use the video and audio elements with the current markup (XHTML1 Strict), I wonder if that is possible and if is there any implication by doing that?


2 answers

danwellman 5600

If the browser supports them they could be used, although the document will not validate. All of your XHTML1 elements will work with the HTML5 doctype though, what is preventing you from updating it?

Answered almost 7 years ago by danwellman
  • Thanks Dan! That's because there's a fairly big amount of pages involved and upgrading to the HTML5 doctype is not an option yet. Also, I think it's overkill to use HTML5 doctype just for the video and audio tags. Fai almost 7 years ago
  • What? Is it overkill to wear pants just because you want your legs to be warm? Andy Ford almost 7 years ago
  • The overkill thing threw me, too. Less code to do the same thing = win. On the other hand, if it aint broke... Olly Hodgson almost 7 years ago
  • Maybe by overkill he meant overkill to bother updating large number of pages? Best answer is still to use HTML5 doctype and continue with XHTML syntax. If the page is being edited anyway to add video/audio, it could just as easily be edited to change doctype, right? Doug almost 7 years ago
cyn 0

Does not work for me. I tried upgrading my page by just changing the doctype and the page layout was affected. Tested on FF3.6.8 and Chrome too. Both support HTML5.

Answered over 6 years ago by cyn