Phonegap 2.3和Android with HTML5 video tag in 2013 [英] Phonegap 2.3 and Android with HTML5 video tag in 2013

查看:325
本文介绍了Phonegap 2.3和Android with HTML5 video tag in 2013的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道这已被问过很多次,大多数有同样的答案:使用videplayer插件。但这不是我们一些人想要播放视频的方式,我们想在内联玩。根据我没有回答。




I know this has been asked many times and most have the same answer: "Use the videplayer plugin". But this is not the way some of us would like to play a video, we want to play in inline. And according to me there is not answer.

http://simonmacdonald.blogspot.ca/2012/10/partial-support-for-video-tag-in.html

Can any one give an answer that plays the video inline in the phonegap webview?

I know poeple are playing html5 video tags in the Android webview (inline), building their own webviews, so what is the problem with phonegap?

I mean can android devices seriously not play html5 video in the phonegap webview in 2013??

Even trying this: (apparently you cant play videos out off the assets folder)

<video id="1" autobuffer width="100%" tabindex="0">
         <source src="file:///videos/video3.mp4" type="video/mp4" />
        </video>

Does not work

<script type="text/javascript">

    $(function(){
        $("video")[0].play()
    });
</script>

Manifest.xml:

<application android:icon="@drawable/icon" android:label="@string/app_name"
        android:hardwareAccelerated="true"
        android:debuggable="true">

解决方案

I recently ran into this problem and created a plugin that accomplishes what you are trying to do.

Here is the repository: https://github.com/jaeger25/Html5Video

这篇关于Phonegap 2.3和Android with HTML5 video tag in 2013的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆