I'm trying to use:
navigator.app.loadUrl("http://www.google.com", { openExternal:true } );
And it does not work for iOS, either on device and simulator. I've used this same line of code in a similar project, and I'm using the same version of phonegap on both (1.5.0). On android the same code works perfectly. The device ready function also fires, so I'm guessing phonegap is being loaded. I'm not using the phonegap.js file of android, I've checked that.
While debugging I found that navigator.app
is an undefined object. Does anybody have any idea of a configuration I might be missing to cause this?
Thanks for your help.
Cheers, Miguel
The "navigator.app" object is only available on Android. Luckily in the soon to be released 2.3.0 version of PhoneGap you will be able to do:
window.open("http://www.google.com", "_system");
to do exactly what you want to do.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With