External access Phonegap

Asked

Viewed 290 times

0

Problem : my app runs cool in emulator however when Gero . apk it does not access internet.

Note: I have not changed anything in config.xml and androidManifests.xml.

1 answer

0


Ezequiel, Phonegap in its own documentation has a detailed explanation regarding the internet access by the App. Follow the link:

https://cordova.apache.org/docs/en/latest/reference/cordova-plugin-whitelist/#supported-Cordova-Platforms

I recommend that you read, because it is of great help.

Run the following commands in your terminal, in your application directory:

$ cordova plugin add cordova-plugin-whitelist
$ cordova prepare

(If it’s windows, you don’t need $)

And add the following line to your config.xml:

<allow-navigation href="*" />

This line basically gives you the authorization to access all web pages through your application.

NOTE: In your config.xml, check if it has any other tag <allow-navigation>, if you have, you can delete it and copy the one I passed on.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.