"Element source not allowed as child of element audio in this context."

Hi again!

 

Testurl

========

http://www.plastic-surgery-estonia.com/html5-test/audio-tag.html

 

HTML5 validator Error:

========

Line 10, Column 50: Element source not allowed as child of element audio in
this context. (Suppressing further errors from this subtree.)

 

Code:

========

<audio controls="controls">
        <source src="audio-clip.mp3
<view-source:http://www.plastic-surgery-estonia.com/html5-test/audio-clip.mp
3> " type="audio/mp3" />
        <source src="audio-clip.ogg
<view-source:http://www.plastic-surgery-estonia.com/html5-test/audio-clip.og
g> " type="audio/ogg" />
        <embed src="audio-clip.mp3
<view-source:http://www.plastic-surgery-estonia.com/html5-test/audio-clip.mp
3> " autoplay="false" type="audio/mp3" />
</audio>

 

Validation:

========

If I remove one source tag it will pass the HTML5 validation, but why is
that?

I need both source tags - Firefox, Opera and Chrome - ogg format. Internet
Explorer and Safari - mp3 format.

 

Question

========

How do I fix the code and pass the HTML5 validation?

 

Thank you.

Kristjan Kure

 

Received on Saturday, 22 October 2011 20:39:33 UTC