Opening website from link in app

Now pressing a href=“http://” ion opens it in App.
How to make it to open it in default browser?

Hi Piernik,
I think what you’re trying to achieve is not really possible in a Cordova App container. This means you will not be able to open the default browser on the Phone. However you should take a look into the Cordova ‘inappbrowser’ plugin ( https://github.com/apache/cordova-plugin-inappbrowser/blob/dev/doc/index.md ). This plugin allows you to open a new browser instance (by adding ‘target="_blank"’ to the link) inside your App which is intended to display external web pages. The downside is that it is still not the Default browser which the user will see but at least it is a clean browser instance and the user can still navigate back to your App.

Kind regards,
Alex

1 Like

I’m able to run native map app using href=“geo:” I think there is a way to open native browser

Hi Piernik,
Opening the Maps App works because there is an intent ( http://developer.android.com/reference/android/content/Intent.html ) active on the Phone which will open a specific App if the requested URL starts with ‘geo:’. Basically the browser does not register an intent on the Phone for URLs starting with ‘http:’ or ‘https:’ and that is why you won’t be able to open the default browser in a Cordova App.

Regards,
Alex

1 Like

Thanks for explaining…

The link to your github repo for in appa browser is broken please update