PhoneGap的构建:如何在设备浏览器中打开外部URL在Android? [英] PhoneGap Build: how to open external url in device browser on Android?
问题描述
外部URL的别在我的PhoneGap的Android应用程序系统的浏览器中打开。我使用的PhoneGap构建2.3.0。
External URL's don't open in the system's browser in my PhoneGap Android application. I'm using PhoneGap Build 2.3.0.
根据<一href="http://cordova.apache.org/docs/en/2.3.0/cordova_inappbrowser_inappbrowser.md.html#InAppBrowser">Cordova文档我用目标的_system:
According to the Cordova documentation I used target '_system':
window.open('http://www.myurl.nl', '_system');
在我的config.xml中我有:
In my config.xml I have:
<plugin name="InAppBrowser" value="org.apache.cordova.InAppBrowser" />
<access origin="*" browserOnly="true" />
但还是在我的应用程序的WebView打开的链接。
But still the links open in my apps webview.
如何解决此问题?
推荐答案
这不是问题的答案,当你想继续使用PhoneGap的构建,但我用我的机器上建立一个开发环境科尔多瓦(PhoneGap的)解决了这个问题,本地编译应用程序。在科尔多瓦2.5.0 的window.open('http://www.myurl.nl','_system');
运行完美,它会打开系统的链接浏览器。
It's not the answer when you want to keep using PhoneGap Build, but I solved the problem by setting up a development environment for Cordova (PhoneGap) on my machine and compiling the app locally. In Cordova 2.5.0 window.open('http://www.myurl.nl', '_system');
works perfect, it will open the link in the system's browser.
所以我的建议是停止使用PhoneGap的建立,并开始在本地编译应用程序。 <一href="http://cordova.apache.org/docs/en/2.5.0/guide_getting-started_android_index.md.html#Getting%20Started%20with%20Android">Here's如何设置的科尔多瓦开发环境>>
So my advice is to stop using PhoneGap Build and start compiling your app locally. Here's how to set up your development environment for Cordova >>
这篇关于PhoneGap的构建:如何在设备浏览器中打开外部URL在Android?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!