-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
How to do a no-cors request to flickr open api? #280
Comments
Flickr does not support CORS headers on jQuery is sending a JSONP request and evaluating the JavaScript served in Flickr's response with an injected |
The issue claims that the fetch is unsuccessful in general. I have tried to do a simple fetch of github.com, as the example demonstrates, and I have been unsuccessful. Is there some trick not included in the example code? |
Cross-origin resource sharing requires the participation of the server via the Compare the results of the following requests: fetch('https://github.com')
fetch('https://api.github.com') |
Thanks, I thought this might be the case, but since the example uses github.com. rather than api.giuthub.com, I thought it might be the case that it was supposed to work. I'll put in a pr to change the example. |
This is more of a question than an issue. A question to you but an issue to me. I'm trying to use fetch to hit the flicker open api, or to make cross origin requests in general, and can't. I've gathered that I should use
mode: 'no-cors'
but that results in an "opaque" response, which doesn't provide me the json data I need.Even though I can see in the network tab that the JSON was sent back with the response, in fact.
Any help would be a big help!?
Here's a codepen. The request works with jquery. Not with fetch.
http://codepen.io/morgs32/pen/OMGEpm
The text was updated successfully, but these errors were encountered: