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

d3.Js request giving Method not allowed error (405) #32

Closed
bhargavakl opened this issue Jan 19, 2018 · 1 comment
Closed

d3.Js request giving Method not allowed error (405) #32

bhargavakl opened this issue Jan 19, 2018 · 1 comment

Comments

@bhargavakl
Copy link

I am trying to request an URL with the headers, below is the request,

d3.json('http://localhost:64453/v4/Production/Dashboard/YieldByLine')
.header("application_key", "aa")
.header("lab_code", "aa")
.get(function (error, data) {
if (error) {
console.log(error);
} else {
console.log(data);
}
});

It is giving me an error (Method not allowed 405 - Response for preflight has invalid HTTP status code 405).

I have enabled the CORS in my API as well. Still, I am getting the issue.

I have tried to execute this in POSTMAN and it is giving me the proper result with this header.

Can anyone please help me to resolve this issue?

Thanks,
Bhargava

@mbostock
Copy link
Member

Please use Stack Overflow tag d3.js to ask for help. Although I make an effort to assist everyone that asks, I am not always available to provide help promptly or directly. Stack Overflow provides a better collaborative forum for self-help: tens of thousands of D3-related questions have already been asked there, and some answered questions may be relevant to you.

When asking for help, please include a link to a live example that demonstrates the issue, preferably on bl.ocks.org. It is often impossible to debug from code snippets alone. Isolate the issue and reduce your code as much as possible before asking for help. The less code you post, the easier it is for someone to debug, and the more likely you are to get a helpful response.

If you have a question about D3’s behavior and want to discuss it with other users, also consider the d3-js Google Group or joining the d3-js Slack.

Thank you! 🤗

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

No branches or pull requests

2 participants