PhoneGap的2.3和Android在2013 HTML5视频标签 [英] Phonegap 2.3 and Android with HTML5 video tag in 2013
问题描述
我知道这已经被问了很多次,大部分都相同的答案:使用videplayer插件。但是,这不是我们中的一些想播放视频的方式,我们希望在在线播放。而根据我有没有回答。
<一个href=\"http://simonmacdonald.blogspot.ca/2012/10/partial-support-for-video-tag-in.html\">http://simonmacdonald.blogspot.ca/2012/10/partial-support-for-video-tag-in.html
任何一个可以给播放视频内嵌在PhoneGap的web视图的答案?
我知道永世正在播放HTML5视频标签在Android的WebView(内置),建立自己的网页视图,所以有什么用PhoneGap的问题是什么?
我的意思是可以的Android设备严重的PhoneGap的网页流量在2013年不能播放HTML5视频??
即使试图这样的:(显然你不能播放视频出关资产的文件夹)
&lt;视频ID =1自动缓冲WIDTH =100%的tabindex =0&GT;
&lt;信源SRC =文件:///videos/video3.mp4TYPE =视频/ MP4/&GT;
&LT; /视频&GT;
不工作
&LT;脚本类型=文/ JavaScript的&GT; $(函数(){
$(视频)[0] .play()
});
&LT; / SCRIPT&GT;
的Manifest.xml:
&lt;应用机器人:图标=@绘制/图标机器人:标签=@字符串/ APP_NAME
机器人:hardwareAccelerated =真
机器人:可调试=真正的&GT;
最近,我遇到了这个问题,并创建了一个插件,完成你正在尝试做的。
下面是仓库: https://github.com/jaeger25/Html5Video
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在2013 HTML5视频标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!