2016-03-15 96 views
10

今天(2016年3月15日)chrome停止使用--disable-web-security標誌。我已經嘗試了各種帖子中描述的以下選項: 1)在Windows任務管理器中殺掉Chrome.exe的所有實例。 2)添加--use-data-dir來標誌,there is a current post regarding this, but the answers there do not work anymoreChrome 49加上--disable-web-security

這裏是我的腳本,我使用:

開始的chrome.exe - 禁用網絡安全--allow - 運行 - 不安全的內容--use-DATA-DIR = C:/溫度/ chrome_dev

Chrome的這個腳本禁用安全警告,但本地主機跨域下打開呼籲仍未:

enter image description here

+0

我看到今天這個太。 – CharlesC

回答

17

我有使用--disable-web-security的解決方案。

最後我找到了解決辦法。現在,如果您將--user-data-dir設置在一起,Chrome會接受它。 當你使用它時你將會有不同的實例。 嘗試:

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --disable-web-security --user-data-dir="D:\chrome" 
+0

我試過了,直接複製批處理腳本,沒有改變,它的工作,謝謝! –

+1

除了使用任意目錄之外,您可以省略user-data-dir的值。以下適用於Windows 10和Chrome 49的操作系統:「C:\ Program Files(x86)\ Google \ Chrome \ Application \ chrome.exe」--disable-web-security --user-data-dir – raider33

+0

很有道理,但似乎爲我工作。 – victor

3

只爲OS X用戶,這個工作對我來說(在埃爾卡皮坦):/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --disable-web-security --user-data-dir="<some-dir>"

也適用於約塞米蒂10.10.5。請注意--user-data-dir可能不再爲空。你必須指定一些目錄。

+4

這對我不起作用,這是'''打開-a/Applications/Google \ Chrome.app --args --disable-web-security --user-data-dir =「」'''' –

1

對於Linux的

google-chrome --user-data-dir=」/var/tmp/Chrome」 --disable-web-security 

我建議一個臨時目錄

1

這適用於鉻61運行過我 -

chrome.exe --user-data-dir="C:/Chrome dev session" --disable-web-security