Re: error code when insering a video using video tag
laurent carcone <[email protected]> Sat, 05 Jan 2013 17:57:41 +0100
| Newsgroups | gmane.comp.web.amaya.general |
|---|---|
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format. --------------080200070103080600060907 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit Hello, Amaya doesn't support html5, it's why it raises an error on the element <video>. Unfortunately, new developments on Amaya are stopped at W3C and Inria. I know there is a project outside W3C to work on the HTML5 support, I'll let you know if I have some update. If you want to add a video in a html page using Amaya, you can use the elements embed or object. Thanks, Laurent Le 05/01/13 17:15, HiddenId a écrit : > Hello All. > Thanks a lot for your returns. > I've still questions: is it better to stay in xhtml or move to html > code type, regarding results described bellow ? > Antoine > > Here is the code I'm testing, including changes you told me: > > ------------------------------- > 23 <video width="320" height="240" controls=""> > 24 <source src="proj.mp4" type="video/mp4" /> > 25 <source src="proj.ogg" type="video/ogg" /> > 26 <source src="proj.webm" type="video/webm" /> > 27 <object data="proj.mp4" width="320" height="240"> > 28 <embed src="proj.swf" width="320" height="240"> > 29 </object> > 30 </video> > 31 <p><strong>Download Video:</strong> > 32 Closed Format:<a href="proj.mp4">"mp4"</a> > 33 Open Format:<a href="proj.ogg">"ogg"</a> > 34 </p> > ----------------------------- > > Then here are results concerning error alerts send back by Amaya: > > Test 1: keeping XHTML code type (transitional 1.0) > ***************************************** > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> > > Amaya returns following errors > > *** Errors/warnings in test.html > line 23, char 0: Invalid or unsupported XHTML element <video> > line 24, char 0: Invalid or unsupported XHTML element <source> > line 25, char 0: Invalid or unsupported XHTML element <source> > line 26, char 0: Invalid or unsupported XHTML element <source> > line 29, char 2: mismatched tag > > Test 2: changing to HTML code type: > ****************************** > <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" > "http://www.w3.org/TR/html4/loose.dtd"> > > Amaya does not return any error. > And Amaya modify the code, erasing the "layout" of the code (see bellow): > > <video width=320 height=240 controls><source src=proj.mp4 type=video/mp4 > /><source src=proj.ogg type=video/ogg /><source src=proj.webm > type=video/webm > /><object data="proj.mp4" width="320" height="240"> > <embed src="proj.swf" width="320" height="240" /></object> </video> > > <p><strong>Download Video:</strong> Closed Format:<a > href="proj.mp4">"mp4"</a> Open Format:<a href="proj.ogg">"ogg"</a> </p> > > Conclusion: > ********** > XHTML: still errors, and code is not changed by Amaya > HTML 4: no error, but code layout is modified > > Then: what should I decide ? > > ------------------------------------------------------------------------ > *De :* Leif Halvard Silli <xn--mlform-iua@målform.no> > *À :* HiddenId <[email protected]> > *Cc :* "[email protected]" <[email protected]> > *Envoyé le :* Samedi 5 janvier 2013 15h46 > *Objet :* Re: error code when insering a video using video tag > > HiddenId, Fri, 4 Jan 2013 17:43:32 +0000 (GMT): > > > I'm trying to insert a video in an HTML page. > > I've tried a w3school code example : > > > > <video width="320" height="240" controls> > > <source src="movie.mp4" type="video/mp4"> > > <source src="movie.ogg" type="video/ogg"> > > <source src="movie.webm" type="video/webm"> > > <object data="movie.mp4" width="320" height="240"> > > <embed src="movie.swf" width="320" height="240"> > > </object> > > </video> > > > Unfortunatly, Amaya returns "an error code": invalid token > > It seems it is the "s" of controls which generate the error. > > > > Do you know what I should do to avoid this error ? > > Firstly, assuming that you work with an XHTML document, then, instead > of controls, you should write controls="" or controls="controls". Then > that particular error message will disappear. This is because XML > requires boolean attributes to be of the shape foo="foo" or foo="". By > contrast, HTML permits the author to type foo (the HTML browser will > still think of it as foo="", however). > > Secondly, the empty <source/> elements must be equipped with a closing > "/", since that is the canonical form of empty elements in XHTML. > > All in all, this would work: > > <video width="320" height="240" controls=""> > <source src="movie.mp4" type="video/mp4" /> > <source src="movie.ogg" type="video/ogg" /> > <source src="movie.webm" type="video/webm" /> > <object data="movie.mp4" width="320" height="240"> > <embed src="movie.swf" width="320" height="240" /> > </object> > </video> > -- > leif halvard silli > --------------080200070103080600060907 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit <html> <head> <meta content="text/html; charset=ISO-8859-1" http-equiv="Content-Type"> </head> <body bgcolor="#FFFFFF" text="#000000"> <div class="moz-cite-prefix">Hello,<br> <br> Amaya doesn't support html5, it's why it raises an error on the element <video>.<br> Unfortunately, new developments on Amaya are stopped at W3C and Inria. I know there is a project outside W3C to work on the HTML5 support, I'll let you know if I have some update.<br> If you want to add a video in a html page using Amaya, you can use the elements embed or object.<br> <br> Thanks,<br> Laurent<br> <br> Le 05/01/13 17:15, HiddenId a écrit :<br> </div> <blockquote cite="mid:[email protected]" type="cite"> <div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"> <div><span>Hello All.</span></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><span>Thanks a lot for your returns. <br> </span></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><span>I've still questions: is it better to stay in xhtml or move to html code type, regarding results described bellow ?</span></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><span>Antoine</span></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><span><br> </span></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Here is the code I'm testing, including changes you told me:</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">-------------------------------<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">23 <video width="320" height="240" controls=""><br> 24 <source src="proj.mp4" type="video/mp4" /><br> 25 <source src="proj.ogg" type="video/ogg" /><br> 26 <source src="proj.webm" type="video/webm" /><br> 27 <object data="proj.mp4" width="320" height="240"><br> 28 <embed src="proj.swf" width="320" height="240"><br> 29 </object><br> 30 </video><br> 31 <p><strong>Download Video:</strong><br> 32 Closed Format:<a href="proj.mp4">"mp4"</a><br> 33 Open Format:<a href="proj.ogg">"ogg"</a><br> 34 </p><br> </div> <div>-----------------------------</div> <div><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Then here are results concerning error alerts send back by Amaya:<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Test 1: keeping XHTML code type (transitional 1.0)</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">*****************************************<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"<br> <a class="moz-txt-link-rfc2396E" href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"</a>></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Amaya returns following errors<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal; margin-left: 40px;">*** Errors/warnings in test.html<br> line 23, char 0: Invalid or unsupported XHTML element <video><br> line 24, char 0: Invalid or unsupported XHTML element <source><br> line 25, char 0: Invalid or unsupported XHTML element <source><br> line 26, char 0: Invalid or unsupported XHTML element <source><br> line 29, char 2: mismatched tag<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Test 2: changing to HTML code type:</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">******************************<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal; margin-left: 40px;"><!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"<br> <a class="moz-txt-link-rfc2396E" href="http://www.w3.org/TR/html4/loose.dtd">"http://www.w3.org/TR/html4/loose.dtd"</a>></div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Amaya does not return any error.</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">And Amaya modify the code, erasing the "layout" of the code (see bellow):</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal; margin-left: 40px;"><video width=320 height=240 controls><source src=proj.mp4 type=video/mp4<br> /><source src=proj.ogg type=video/ogg /><source src=proj.webm type=video/webm<br> /><object data="proj.mp4" width="320" height="240"><br> <embed src="proj.swf" width="320" height="240" /></object> </video><br> <br> <p><strong>Download Video:</strong> Closed Format:<a<br> href="proj.mp4">"mp4"</a> Open Format:<a href="proj.ogg">"ogg"</a> </p><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">Conclusion:</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;">**********</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal; margin-left: 40px;">XHTML: still errors, and code is not changed by Amaya</div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal; margin-left: 40px;">HTML 4: no error, but code layout is modified<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal; margin-left: 40px;">Then: what should I decide ?<br> </div> <div style="color: rgb(0, 0, 0); font-size: 16px; font-family: times new roman,new york,times,serif; background-color: transparent; font-style: normal;"><br> </div> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <font face="Arial" size="2"> <hr size="1"> <b><span style="font-weight:bold;">De :</span></b> Leif Halvard Silli <a class="moz-txt-link-rfc2396E" href="mailto:xn--mlform-iua@målform.no"><xn--mlform-iua@målform.no></a><br> <b><span style="font-weight: bold;">À :</span></b> HiddenId <a class="moz-txt-link-rfc2396E" href="mailto:[email protected]"><[email protected]></a> <br> <b><span style="font-weight: bold;">Cc :</span></b> <a class="moz-txt-link-rfc2396E" href="mailto:[email protected]">"[email protected]"</a> <a class="moz-txt-link-rfc2396E" href="mailto:[email protected]"><[email protected]></a> <br> <b><span style="font-weight: bold;">Envoyé le :</span></b> Samedi 5 janvier 2013 15h46<br> <b><span style="font-weight: bold;">Objet :</span></b> Re: error code when insering a video using video tag<br> </font> </div> <br> HiddenId, Fri, 4 Jan 2013 17:43:32 +0000 (GMT):<br> <br> > I'm trying to insert a video in an HTML page.<br> > I've tried a w3school code example :<br> > <br> > <video width="320" height="240" controls><br> > <source src="movie.mp4" type="video/mp4"><br> > <source src="movie.ogg" type="video/ogg"><br> > <source src="movie.webm" type="video/webm"><br> > <object data="movie.mp4" width="320" height="240"><br> > <embed src="movie.swf" width="320" height="240"><br> > </object> <br> > </video> <br> <br> > Unfortunatly, Amaya returns "an error code": invalid token<br> > It seems it is the "s" of controls which generate the error.<br> > <br> > Do you know what I should do to avoid this error ?<br> <br> Firstly, assuming that you work with an XHTML document, then, instead <br> of controls, you should write controls="" or controls="controls". Then <br> that particular error message will disappear. This is because XML <br> requires boolean attributes to be of the shape foo="foo" or foo="". By <br> contrast, HTML permits the author to type foo (the HTML browser will <br> still think of it as foo="", however).<br> <br> Secondly, the empty <source/> elements must be equipped with a closing <br> "/", since that is the canonical form of empty elements in XHTML. <br> <br> All in all, this would work:<br> <br> <video width="320" height="240" controls=""><br> <source src="movie.mp4" type="video/mp4" /><br> <source src="movie.ogg" type="video/ogg" /><br> <source src="movie.webm" type="video/webm" /><br> <object data="movie.mp4" width="320" height="240"><br> <embed src="movie.swf" width="320" height="240" /><br> </object> <br> </video><br> -- <br> leif halvard silli<br> <br> </div> </div> </div> </blockquote> <br> </body> </html> --------------080200070103080600060907--