-
Notifications
You must be signed in to change notification settings - Fork 6k
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
Using cors-anywhere with local filesystem #323
Comments
How did you set up your own instance of CORS Anywhere? Which browser are you using? |
I followed the guide and deployed to a Heroku instance out of the box (though I did try a slight modification of removing the requireHeader parameter to see if it would fix the problem). For browser, I've tried Chrome and Opera. This is the response, indicating it's missing the origin (since it's coming from the filesystem): |
Did you fork CORS Anywhere and change anything? The error message indicates that you're receiving a cors-anywhere/lib/cors-anywhere.js Line 54 in 9f1af82
|
Nope, I did not fork it, just cloned it and deployed it as is. Here is a full sample html file that I just threw together to verify:
When I run this in localhost, it works as expected and prints the contents to the console. However, when I run it from the file system directly, it shows the error as described earlier: Please let me know if I'm doing something wrong! |
Also tried the following, which is more or less taken straight from the demo code, with as little modifications as possible - same result.
|
I cannot reproduce your issue in Chrome or Firefox. Can you share a test case that reproduces the same issue in a clean install of either browser? |
Interesting. The test code above reproduces the scenario in both Chrome and Opera for me, but I just tried Firefox and it works fine. It also works in Edge. You're able to run the above code in Chrome without an access denied error? I do know this used to work in both Chrome and Opera. |
Works for me in both Firefox and Chrome, this includes Chromium 89. |
Hi, Extreme newbie web developer here, so apologies in advance.
I had previously been using cors-anywhere with a local app I have built for myself, that I ran directly through the file system. With the recent disabling of the public server, I am now hosting my own instance of cors-anywhere. I have verified that if I deploy my client app to localhost, I can make the requests correctly. However, if I run through the file system directly (ie through
file:
syntax), the requests are blocked.I would assume that this sort of request isn't possible, except that it was working previously with the public server :) Any idea what I'm missing?
The text was updated successfully, but these errors were encountered: