时间:2021-07-01 10:21:17 帮助过:215人阅读
这是HTML5嵌入视频的简单方法,可以然你快速的将视屏嵌入
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "www.gxlcms.com/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title>HTML5 Video Demo</title> </head> <body> <p style="width: 667px; margin: 0 auto;"> <video width="667" height="375" controls> <source src="FILE_NAME.mp4" type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"' /> <source src="FILE_NAME.ogv" type="video/ogg" /> <object width="667" height="375" type="application/x-shockwave-flash" data="FILE_NAME.swf"> <param name="movie" value="FILE_NAME.swf" /> <param name="flashvars" value="controlbar=over&image=PLACEHOLDER_FILE_NAME.jpg&file=FILE_NAME.mp4" /> <img src="PLACEHOLDER_FILE_NAME.jpg" width="250" height="152" alt="ALT_HERE" title="TITLE_HERE" /> </object> </video> </p> </body> </html>
以上就是分享一个简单的HTML5 视频嵌入实例代码的详细内容,更多请关注Gxl网其它相关文章!