文档似乎说可以啊……然而我在我的 MIUI 上并没有试验成功……
顺便服务端不可控而且对源 IP 敏感……
1 clker 2015-05-07 17:55:55 +08:00 你可以先搜索下吗 |
2 pandada8 OP @clker Running on a device What happens when you run ionic run? Your files for the app are copied to the device (or simulator). The app runs, thus firing a browser on the phone/simulator to run the files that were copied over, something like: file://some/path/www/index.html. Your origin will not exist, since you are running off of a file:// URI; therefore, any request outwards will not require a CORS request. 然而我没开任何的live reload,在设备上和模拟器都无法发请求 |
![]() | 3 xylitolLin 2015-05-07 23:20:57 +08:00 把那个<meta access-orgin......>(忘了具体是什么),删了不行吗? |
![]() | 4 wangxiao2015 2015-06-17 20:49:11 +08:00 可以参考官方的这篇 Blog http://blog.ionic.io/handling-cors-issues-in-ionic/ |