ionic cordova not load data from server on devices -
i new ionic application development. using ionic sample project site. problem works fine in browser. not load data server on device.
error message shows
failed load resource: server responded status of 404 (not found)
given can't add comment (sad true), i'll use full blown answer. take @ answer published here, looks same issue: https://stackoverflow.com/a/29953668/4509672
highlights it:
depending on cordova version, seen @ cordova android 4.0.0 announcement, since cordova 4.0.0 must add cordoba-
whitelist functionality revamped
- you need add new cordova-plugin-whitelist plugin continue using whitelist
- setting content-security-policy (csp) supported , recommended way whitelist (see details in plugin readme)
- network requests blocked default without plugin, install plugin allow requests, , if using csp.
- this new whitelist enhanced more secure , configurable, legacy whitelist behaviour still available via separate plugin (not recommended).
- note: while not strictly part of release, latest default app created cordova-cli include plugin default.
Comments
Post a Comment