Ionic requests return 404 only on android, in Chrome it works fine

So, i have cloned the tutorial app repo from ionic. I ran

ionic start conference sidemenu

and then i added a simple $http.get('myserver')(I tried with ngResources too).

It worked perfect on chrome, I got all the data back but on angular i only got null data and 404 status on any request I tried to do.

Note: I tried with my hosted server and with a local one. Both fail on Android. Server is a node.js REST API.

Nothing is printed on the console, so the request does not even get to the server.

Has anyone experienced that or could tell me how can I debug Android apps built with Ionic?

EDIT 1: I don`t know why do you need it but here it is

$http.get('http://server.com/route').success(function (data) {
            //handle success
        }).error(function (data, status) {
            // handle error
        });

I`m sorry for answering my question. Here is the solution.

The thing is that there were some major changes in Cordova 4.0.0 like:

Major Changes [...] - Whitelist functionality is now provided via plugin (CB-7747) The whitelist has been enhanced to be more secure and configurable Setting of Content-Security-Policy is now supported by the framework (see details in plugin readme) You will need to add the new cordova-plugin-whitelist plugin Legacy whitelist behaviour is still available via plugin (although not recommended).

So I installed https://github.com/apache/cordova-plugin-whitelist. And added

<allow-navigation href="http://*/*" />

in my config.xml file.

This sounds like you use crosswalk. In that case this will help you: http://forum.ionicframework.com/t/crosswalk-and-http-doesnt-work/20275 I suggest reading the whole thread before changing anything.