[英]How to open an external app in Cordova/Ionic?
I'm working on an ionic app. 我正在开发离子应用程序。 In my app I want to have a button that will open another app.
在我的应用程序中,我想要一个可以打开另一个应用程序的按钮。 I tested the hyper link in safari and the link opens the app correctly, but when I click the button inside my Ionic app, it's not working.
我在Safari中测试了超级链接,该链接可以正确打开该应用程序,但是当我单击Ionic应用程序中的按钮时,它不起作用。 The Xcode reports
Xcode报告
Failed to load webpage with error: The URL can't be shown
无法加载网页,并显示以下错误:无法显示网址
Any suggestions? 有什么建议么?
If you are trying to use externally hosted web application in your cordova application, check out cordova-hosted-webapp-plugin . 如果您尝试在cordova应用程序中使用外部托管的Web应用程序,请签出cordova-hosted-webapp-plugin 。 The plugin enables using content hosted in a web site inside a Cordova application by providing a manifest that describes the site.
该插件可通过提供描述站点的清单来使用Cordova应用程序内部网站中托管的内容。 Also it lets you use the features of Cordova plugins too.
它还使您也可以使用Cordova插件的功能。
But if you are trying to just invoke the external web URL from your cordova app, you can make use of cordova-InAppBrowser-Plugin which opens the web URL inside the app itself. 但是,如果您尝试仅从cordova应用程序调用外部Web URL,则可以使用cordova-InAppBrowser-Plugin来在应用程序内部打开Web URL。
You can also check out cordova-themeable-browser-plugin which is almost similar to InApp browser plugin and provides more control on the browser elements available in the UI. 您还可以签出cordova-themeable-browser-plugin ,它几乎与InApp浏览器插件相似,并提供了对UI中可用浏览器元素的更多控制。 Hope it helps
希望能帮助到你
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.