Crossdomain settings in Google Chrome

2019-01-24 12:01发布

问题:

I'm wondering, in IE & Firefox you're able to setup the browser, to allow cross-domain calls.

I can't find any option in chrome for that (actually, there are in general not too much options at all...)

are there any about:config like things?

Kind Regards

--Andy

回答1:

No. Sorry.

Chrome and Firefox, however do support cross-domain requests via the W3C CORS spec (Cross Origin resource sharing) however the remote host has to enable it. If the remote host supports it explicitly then you don't have to make any changes to your XMLHttpRequest to be able to fetch the content.



回答2:

This answer was correct when written, but is longer correct, the switch has been deprecated

Chrome has a command line switch for this:

chrome.exe --disable-web-security

You can view a full list (as of when it was posted!) of command line options for chrome here.



回答3:

You can install chrome plugins which enable cross-origin resource sharing .

I use this .