5x5 semi-finished HTML5 VIDEO and 5x5 semi-finished html5 video

Source: Internet
Author: User

5x5 semi-finished HTML5 VIDEO and 5x5 semi-finished html5 video

The story is a little long. You can check out the patience of html5.

Those who have worked or have been familiar with HTML5 technology may all know that HTML5 seems to be very popular over the past two years. Many technical enterprises are switching like HTML5 technology or want to use some HTML5 technical features to solve some problems in production. functions such as the WEB storage canvas drag and drop drag some novel CSS3 elements audio/video and so on.

Next, I want to talk about our story. Because we want to engage in video websites to play videos, of course, the company leaders value HTML5 video. Because we all know that Flash is a plug-in, and some of them make browsers unresponsive. some of the issues with the crash have been limited for cross-platform support. It seems that flash is not supported on IOS. So we chose some browsers to support HTML5. For Some browsers that are not supported, we recommend users to upgrade the browser in HTML5. on the official website, there are some standards to support browser requirements, such as IE 9 + Firefox 3.6 +. After this period of research, I found that Google's support for HTML5 video is the best. of
However, when the problem arises, let's take a look at whether you have encountered the same problem as me. I hope you can make a generous effort to explore and study the HTML5 that makes me feel a little bit painful.

The problem has occurred: everyone's attention

IE 10 or IE11 uses the canplaytype API of the official website to test whether it is support, but some cannot play VIDEO. Some cannot even play the VIDEO. Some will have a red X, prompting that the VIDEO format is invalid. I have two problems with this pain point.

Whether accessing the server locally or on the server, we have configured the mime-type video/mp4 Apache on the application server, including IIS. Needless to say, you do not need to configure it.

The next research is not about whether the browser supports HTML5 video, but about whether it supports the encoding in it. Because various browsers support different IE support for video encoding, H264 Firefox supports the latest version of ogg. this Firefox 31 version supports H264 encoding, which may be rare in the harmonious scenario between Microsoft and Firefox. It should be because Microsoft supports Firefox, which has supported HTML5 VIDEO formats since then. if I have more, it means better support for HTML5 video, but I still haven't solved the problem. Why can I play MP4 (H264) using IE11 installed on my machine and my leader's notebook) the two cases of my colleagues who cannot play the video can't be played by two machines are different. This makes me even more disgusting. My colleague is totally unable to support H264 encoding, including the latest firefox version. canplaytype ("video/mp4") is not supported ") return to empty colleague 2? canplaytype ("video/mp4 ") Probably "very likely to support" to see this api I feel disgusting support is not supported, but they did not make it right, and colleague 2 HTML5 WSC official site on the http://www.w3school.com.cn/html5/html_5_video_dom.asp page the video cannot be played out, but "Try it yourself" http://www.w3school.com.cn/tiy/t.asp? F = html5_video_dom: This page can play a video, but the HTML test file gets a local file and obtains the app server. The app Server includes video resources, and the local file gets a local file. Y is bad. It hurts me. he's a computer, but he's not a company.

I forgot to talk about the following prerequisites to avoid some children's shoes saying that my problem description is unclear. My colleagues and I both use WINDOWS SERVER 2008SR IE11 Firefox 30-31. My supervisor is WIN7 IE11.

We have found a lot of website materials, including msdn, but there are too few materials to discuss HTML5 VIDEO, which makes us helpless. My colleagues reinstalled ie from IE11 to IE10 two times in order to cooperate with me. in IE11, it still does not support H264 encoding and cannot be played. Later, I learned whether this H264 encoding is not related to the browser. It is a coding and decoding tool provided by the operating system. I am so worried that he has reinstalled the system to support my greatness. as a result of your career, we have come to think of a tragic story first. Now, we have time to continue our research and find out the essence of the problem. Then we will tell you to remember "no zuo no die ".

In the afternoon, I finally broke through the Windows SERVER 2008 SR system. Now I cannot guarantee all unexpected situations. However, after this time of painstaking research, I will solve the problem that some systems should support HTML5. technical solution for force playback: 2008 cannot be played here. Three points are revealed. One is the configuration in server management. The other is the browser security settings. The third is that the default 2008 is missing an installation package. This is a bit of a problem. you can leave a message to consult





HTML5 VIDEO

HTML5 is the latest standard of HTML. Although it is still not perfect, Some browsers have supported some HTML5 features. Currently, FIREFOX, OPERA, CHORME and IE9 support HTML5, but IE6-IE8 does not support it. Because 360, roaming, windows of the world all use the IE kernel, which is similar to IE in fact, so HTML5 is not supported.
 
How does html5 change the src attribute of video?

<! DOCTYPE html>
<Html>
<Head>
<Title> test video </title>
<Script src = "code.jquery.com/jquery-latest.js"> </script>
</Head>
<Body>
<Div>
<Input type = "text" placeholder = "enter video url to play." id = "t_url">
<Input type = "button" value = "play" id = "t_btn">
<Video src = "movie.ogg" controls = "controls" autoplay = "false" id = "v_video" preload = 'no'>
Your browser does not support video tags.
</Video>
</Div>
<Script type = "text/javascript">
$ (Function (){
$ ("# T_btn"). click (function (){
If (! $ ("# T_url"). val ()){
Alert ("url cannot be blank .");
} Else {
$ ("# V_video"). attr ("src", $ ("# t_url"). val (); // update the url
$ ("# V_video"). attr ("autoplay", "true"); // play directly
}
});
});
</Script>
</Body>
</Html>
It has been tested and chrome is perfectly implemented. It will be played directly after the update. Please adopt it!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.