I have an application that was developed in XDK. The app links to an external web site at one point (for a PDF actually).
I've tried both window.open(url,"_system")
and intel.xdk.device.launchExternal(url)
and both work on IOS and Android when using the Intel App Preview app.
However, once the build was completed and the app was uploaded to the Play store, the external links do not work. I can't say about IOS yet because Apple hasn't finished testing the app, but on Android, it's as though the link doesn't exist. There is no response at all. Even adding a try/catch loop didn't produce any more information.
I realize that because the link produces a PDF that the Android device has to have a PDF viewer installed to view it, however my testing device does have one, and as mentioned when run from App Preview, it downloads the PDF and prompts to view it in Adobe.
Any ideas? Is there a plugin I have to check off for Cordova options for launchExternal to work?
In order to use
intel.xdk.device.launchExternal(url)
, you are required to include the Device plugin under the Intel XDK Plugins group on the Projects Panel > Cordova 3.X Hybrid Mobile App Settings > Included Plugins > Featured & Custom Cordova Plugins > Device.In order to use
window.open(url,"_system")
to open a URL leveraging the Cordova inAppBrowser plugin, you are required to include the In App Browser plugin on the Projects Panel > Cordova 3.X Hybrid Mobile App Settings > Included Plugins > Standard Cordova Plugins > In App Browser.Please note that intel.xdk.device.launchExternal has now been deprecated. Use the default inappbrowser APi like this: window.open("market://details?id=","_blank","location=no")