Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable CORS on your API? #73

Closed
mathew-kurian opened this issue Nov 19, 2015 · 7 comments
Closed

Enable CORS on your API? #73

mathew-kurian opened this issue Nov 19, 2015 · 7 comments

Comments

@mathew-kurian
Copy link

Hey guys, this is this the 4playdb team. Currently we are using a local copy of you data (since you don't have CORS) on our page to do some lookup...essentially a "widget" on our game page. Please enable CORS and if you think of a better usage of your API let us know! As you can see we are not very creative.

@mathew-kurian mathew-kurian changed the title Hey guys can you enable CORS on your API? Enable CORS on your API? Nov 19, 2015
@mathew-kurian
Copy link
Author

XMLHttpRequest cannot load http://hardcarry.me/api/abilities/. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://4playdb.me' is therefore not allowed access.
24024:1 XMLHttpRequest cannot load http://hardcarry.me/api/champions/. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://4playdb.me' is therefore not allowed access.
24024:1 XMLHttpRequest cannot load http://hardcarry.me/api/summoners/. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://4playdb.me' is therefore not allowed access.

@clintburgos
Copy link
Collaborator

@bluejamesbond should be good now. try it and lemme know

@mathew-kurian
Copy link
Author

@clintburgos its still not working. you can test it by visiting our link and checking the Chrome console

@Sweetman
Copy link
Owner

@bluejamesbond any advice on how to fix this? we've tried changing flask cors settings a few times but no luck. is there something on the rackspace server itself we need to set up?

@clintburgos
Copy link
Collaborator

also I saw somewhere online you may be able to bypass it with angular's $resource feature.
https://docs.angularjs.org/api/ngResource/service/$resource
maybe give that a try!

@Sweetman
Copy link
Owner

@bluejamesbond it is fixed

@mathew-kurian
Copy link
Author

Sorry, I didn't see your messages in time. Anyways, glad its resolved. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants