【发布时间】:2014-05-29 06:20:50
【问题描述】:
遵循 Restangular 的文档并包含一个示例:
// GET to http://www.google.com/ You set the URL in this case
Restangular.allUrl('googlers', 'http://www.google.com/').getList();
我正在尝试为 angel.co 做同样的事情
$scope.trial = Restangular.allUrl('googlers', 'https://api.angel.co/1/users/267770').getList();
并且不断出错
XMLHttpRequest cannot load https://api.angel.co/1/users/267770. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:8000' is therefore not allowed access.
有什么解决办法吗?
【问题讨论】:
标签: angularjs angularjs-service restangular