Allow Google Chrome to use XMLHttpRequest to load a URL from a local file

后端 未结 4 2082
猫巷女王i
猫巷女王i 2020-11-22 07:41

When trying to do a HTTP request using XMLHttpRequest from a local file, it basically fails due to Access-Control-Allow-Origin violation.

However, I\'m

4条回答
  •  旧时难觅i
    2020-11-22 08:14

    Mac version. From terminal run:

    open /Applications/Google\ Chrome.app/ --args --allow-file-access-from-files
    

提交回复
热议问题