When I run my application either in the Android emulator or on my Android device, I get an error after all AJAX requests:
Failed to load resource: the server responded with a status of 404 (Not Found)
I tried to follow all the following steps to solve this problem, but it persists.
- Installed a whitelist plugin in a project using npm.
- Added
<plugin name="cordova-plugin-whitelist" version="1" />to config.xml. - Added
<uses-permission android:name="android.permission.INTERNET" />
to platforms \ android \ AndroidManifest.xml. - Added
<meta http-equiv="Content-Security-Policy" content="default-src * 'unsafe-inline';">and <meta http-equiv="X-XSS-Protection" content="0">a file <head>file www / index.html. - Added
<access origin="*" />, <allow-navigation href="*" />and
<allow-intent href="*" />to the config.xml file.
Despite this, I still get the same errors. Any ideas?
The project compiles fine. I am on Windows 7 using Cordova 5.4.0, Android 5.1.1