1, or the first
Ie9+,ff,chrome,,,
Ie78:
2. No BB, on the code!
Directory structure:
Source:
1 <!DOCTYPE HTML>2 <HTML>3 <Head>4 <MetaCharSet= "Utf-8">5 <title>Spring 3.x MVC HTML5 VIDEO</title>6 <Linkhref= "Js/videojs/video-js.css"rel= "stylesheet">7 <Scriptsrc= "Js/jquery-2.1.0.min.js"></Script>8 <!--If you ' d like to support IE8 -9 <Scriptsrc= "Js/videojs/videojs-ie8.min.js"></Script>Ten <!--[If Lt IE 9]> One <script type= "Text/javascript" src= "Js/html5.js" ></script> A <! [EndIf] - - <styletype= "Text/css"> - /*HTML5*/ the Article,aside,dialog,footer,header,section,footer,nav,figure,menu{ - Display:Block; - } - . Videos_container{ + width:650px; - } + </style> A </Head> at - <Body> - < Sectionclass= "Videos_container"> - <VideoID= "My-video"class= "Video-js vjs-default-skin vjs-big-play-centered"src= "Videos/popin.mp4"controls preload= "Auto"width= "640"Height= " the"Poster= "Images/confident.jpg"Data-setup="{}"> - <Sourcesrc= ' Videos/popin.mp4 'type= ' Video/mp4 '></Source> - <Sourcesrc= ' VIDEOS/POPIN.WEBM 'type= ' VIDEO/WEBM '></Source> in <!--<source src= ' videos/popin.ogg ' type= ' Video/ogg ' ></source> - - <ObjectID= "Flash_fallback_1"class= "Vjs-flash-fallback"width= "640"Height= " the"type= "Application/x-shockwave-flash"Data= "js/videojs/flowplayer.swf"> to <paramname= "movie"value= "js/videojs/flowplayer.swf" /> + <paramname= "allowFullScreen"value= "true" /> - <paramname= "Flashvars"value= ' config={' playlist ": [" images/confident.jpg ",{"url": "Videos/popin.mp4", "AutoPlay": false, "autobuffering": True}]} ' /> the <imgsrc= "Images/confident.jpg"width= "280"Height= " the"alt= "Poster Image"title= "No video playback capabilities." /> * </Object> $ <!--If you have an object that is compatible with ie6,7,8, then you don't need the following .Panax Notoginseng <p class= "Vjs-no-js" > - to view this video, enable JavaScript, and consider upgrading to a Web browser that the <a href= "http://videojs.com/html5-video-support/" target= "_blank" >supports HTML5 video</a>
+ </p> A - the </Video> + </ Section> - <Scriptsrc= "Js/videojs/video.js"></Script> $ <Scripttype= "Text/javascript"> $ $(function(){ - videojs.options.flash.swf= "js/video-js.swf"; - }); the </Script> - </Body>Wuyi </Body> the </HTML>
3. Precautions
Other no problem, directly into the video css,js, directly write video content can be.
Mainly ie78: (MLGB. Wc..! @#$^*&% ...)
A) if the IE low version introduces html5.js and adds the style */*HTML5*/ Article,aside,dialog,footer,header,section,footer,nav, Figure,menu{ display:block; } to support HTML5, Videojs-ie8.min.js is a separate introduction for IE8.
b) The video tag needs to have the SRC attribute and provide MP4 format
c) inside the video tag to add an object tag, used in the low version of IE Flash load video, I wrote the MP4 format, online said FLV format is also supported, but I have a problem here, for the moment I do not know why
D) It seems that IE8 needs HTTP support, which means it needs to be tested on the server and not locally
4. References, addresses and the practice source code
Resources:
VIDEOJS official website
Qing Feng Cao Tang
This practice source code 360 Cloud disk access password e898
VIDEOJS Practice-compatible ie7,8