Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Phonegap Android InAppBrowser not working

I am working on an Android App with Phonegap Cordova-3.0.0 and when I call InAppBrowser I got MotionEvent mTouchMode = 4 error. And InAppBrowser function is not working. So how can I fix this? Do I need do some setting on AndroidManifest.xml or config.xml? And I got this on my AndroidManifest.xml

<uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

And I got this on my config.xml

<plugins> <plugin name="InAppBrowser" value="org.apache.cordova.InAppBrowser" /> </plugins>

like image 521
Wen Avatar asked Jul 25 '13 04:07

Wen


1 Answers

In Phonegap Cordova-3.0.0 version, for the app to communicate closely with various device-level features, we need to add plugins that provide access to core Cordova APIs.

The cordova plugin add command requires you to specify the repository for the plugin code. For example, In-app browser:

$ cordova plugin add https://git-wip-us.apache.org/repos/asf/cordova-plugin-inappbrowser.git

we need run this in command line. Don't need worries about AndroidManifest.xml or config.xml files. After you run $ cordova build, it will auto write for you.

You could get more idea about it in doc.phonegap

like image 168
Wen Avatar answered Sep 24 '22 16:09

Wen