Where did you install Firefox from? Help Mozilla uncover 3rd party websites that offer problematic Firefox installation by taking part in our campaign. There will be swag, and you'll be featured in our blog if you manage to report at least 10 valid reports!

Mozilla 도움말 검색

고객 지원 사기를 피하세요. 저희는 여러분께 절대로 전화를 걸거나 문자를 보내거나 개인 정보를 공유하도록 요청하지 않습니다. "악용 사례 신고"옵션을 사용하여 의심스러운 활동을 신고해 주세요.

Learn More

How to enable SOAP request from javascript?

more options

i am developing a simple script for accessing a web-service. I do a request from my javascript, but firefox blocks this request and in console writes "Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at http://www.guru4.net/articoli/javascript-soap-client/demo/webservicedemo.asmx?wsdl. This can be fixed by moving the resource to the same domain or enabling CORS." How to enable this damn CORS in firefox?

i am developing a simple script for accessing a web-service. I do a request from my javascript, but firefox blocks this request and in console writes "Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at http://www.guru4.net/articoli/javascript-soap-client/demo/webservicedemo.asmx?wsdl. This can be fixed by moving the resource to the same domain or enabling CORS." How to enable this damn CORS in firefox?

글쓴이 NoahSUMO 수정일시

모든 댓글 (3)

more options

It's not about enabling CORS in Firefox, relax.

CORS must be enabled at the server-side, this is an error for security, Every browser throws this error.

In order to activate CORS in your server you must send these headers:

    Access-Control-Allow-Origin: <yourUrlToAllowAccess>

More about this at MDN

+ Please test your code on other browsers before acting like this, if it's the same across browsers, stackoverflow is the place to ask your question.

글쓴이 Mahdi Dibaiee 수정일시

more options

hmmm, does it mean that my client is forbiddent to access this server? I am not related to this server and cannot to reconfigurate it. I can access this web-service http://www.guru4.net/articoli/javascript-soap-client/demo/webservicedemo.asmx?wsdl using wsdl-browser http://wsdlbrowser.com/, but it doesn't work when I invoke this service from my javascript-code

more options

Yes, the server has disabled CORS, that's why you can't access it using JavaScript. You can open it with any browser, but you can't access it from another origin ( i.e. your website )

글쓴이 Mahdi Dibaiee 수정일시