且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

< video src ="">之间的差异< / video>和<视频> <信源> < /源>< /视频> ;?

更新时间:2021-09-08 07:24:41

使用< video> <信源&GT; &LT; /源&GT; &LT; /视频&GT;
您可以添加多个源元素。
多个源元素可以链接到不同的视频文件。浏览器将使用第一种识别格式。

By using <video> <source> </source> </video>. You can add multiple source elements. Multiple source elements can link to different video files. The browser will use the first recognized format.

 <video width="320" height="240" controls>
<source src=http://techslides.com/demos/sample-videos/small.webm type=video/webm> 
  <source src=http://techslides.com/demos/sample-videos/small.ogv type=video/ogg> 
  <source src=http://techslides.com/demos/sample-videos/small.mp4 type=video/mp4>
  <source src=http://techslides.com/demos/sample-videos/small.3gp type=video/3gp>
Your browser does not support the video tag.
</video>