Pergunta

I tried mediaelement.js and it worked in 5 min in all modern browsers with mp4, ogg and webm. Then I tried IE 8 - no function. A black player window with controls, but no function. I tried the css-tipp (static vs absolut in .me-plugin). I tried absolute and relative paths. Nothing worked. I tried with and without the mp4 source in IE8 - no function. Without the line for mp4 it is not working in any browser, like there isnt any flash-fallback. Here is my code:

<head>
    <script src="jquery.js"></script>
    <script src="libs/mediaelement/build/mediaelement-and-player.min.js"></script>
    <link rel="stylesheet" href="libs/mediaelement/build/mediaelementplayer.css" />
</head>
<body>
<video  id="player1" width="320" height="240" controls="controls">
    <!-- MP4 for Safari, IE9, iPhone, iPad, Android, and Windows Phone 7 
    <source type="video/mp4" src="resources/media/testvideo.mp4" ></source>-->
    <!-- Flash fallback for non-HTML5 browsers without JavaScript -->    
    <object width="320" height="240" type="application/x-shockwave-flash" data="/Webinar/libs/mediaelement/build/flashmediaelement.swf">
        <param name="movie" value="/Webinar/libs/mediaelement/build/flashmediaelement.swf" /> 
        <param name="flashvars" value="controls=true&amp;poster=myvideo.jpg&amp;file=/Webinar/resources/media/testvideo.mp4" /> 
    </object>
</video>
</body>

Can someone tell me, whats wrong with my code?

Foi útil?

Solução

After some more research I got the solution for myself. Im a noob - the flashplayer was not updated.

Here are two maybe useful hints i needed for mediaelement.js: 1. The flashfallback works only if there is also a <source> Element for some other format in the <video> element and not only the <object> element for flash. 2. The fullscreen mode in IE 8 works only, if the <object> gets following parameter: <param name="allowFullScreen" value="true" />

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top