Local my own Rest URL is not working

Hi,

I am trying to access my own Rest URL with IONIC frame work($http.get) but not able to access this URL.
I tried with

in config.xml but no response.

Please provide me some tutorial to access my own Rest URL which solves cross domain Issue also.

regards,
suresh

check this out
http://blog.ionic.io/handling-cors-issues-in-ionic/

Hi,
Already i tried this URL by modifying ionic.project.
after adding

“proxies”: [
{
“path”: “/api”,
“proxyUrl”: “http://cors.api.com/api
}
] I am not able execute ionic serve command and below error i am getting.

Error occured [Error: There was an error loading your ionic.project file: Unexpe
cted string]

TypeError: Utils.fail is not a function
at Object.IonicTask.run (C:\Users\sureshkumar\AppData\Roaming\npm\node_modul
es\ionic\lib\ionic\serve.js:38:18)
at Object.run (C:\Users\sureshkumar\AppData\Roaming\npm\node_modules\ionic\l
ib\cli.js:95:32)
at Object. (C:\Users\sureshkumar\AppData\Roaming\npm\node_modules
\ionic\bin\ionic:9:10)
at Module._compile (module.js:425:26)
at Object.Module._extensions…js (module.js:432:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:313:12)
at Function.Module.runMain (module.js:457:10)
at startup (node.js:138:18)
at node.js:974:3

Utils.fail is not a function (CLI v1.7.11).

Please suggest me on this.

regards,
suresh

Hi,
I modified ionic.project file and able to execute ionic serve command but not able to get data from Rest URL.
Any thing else missing apart from modifying ionic.project file with “proxies”.

regards,
suresh

Hi,
Now i am able to get data from Rest URL through browser by executing ionic serve but not able to get through android simulator. I tried with modifying gulpfile.js file by adding and removing proxy.

Please advice for getting Rest URL data from android simulators what we need to do.
do we need replace Rest URL or ionic frame work URL in gulpfile.
I tried with replacing ionic frame work running URL in gulpfile.

regards,
suresh

do you have added the whitelist plugin to your project? if not… all requests are blocked per default.

Hi,
Please send me URL link for whitelist plugin ,so that i can download this plugin and add into project.

regards,
suresh

and questions like “send me url”…
http://www.giyf.com/

:wink: