Cross-domain settings for Windows & Mac Chrome-includes two settings, both before and after version 49

Source: Internet
Author: User

when the WebApp is developed, it is often necessary to set the browser to support cross-domain mode for some reason, but the Chrome browser supports cross-domain settings, and there are many chrome cross-domain Setup tutorials on the web. But the new version of Chrome has raised the threshold for cross-domain settings, and the original method no longer applies. The following is a brief introduction to the new version of Chrome's cross-domain setting method.

Cross-domain settings prior to version number 49

First introduce the old method, refer to some online tutorials, in fact, directly on the Open command to add--disable-web-security on it.

Specific practices are:

1. After downloading and installing the Chorme browser, locate the browser shortcut icon on the desktop and click the right mouse button's property column.
2. Add--disable-web-security to the target input box in the Properties page as shown:

3. Click Apply and OK to close the Properties page and open the Chrome browser. If the browser prompts "you are using an unsupported command tag--disable-web-security", the configuration is successful.

Mac method: Because the app in your Mac doesn't have properties like windows, you need a command to open the browser

Launch chrome:open-a "Google Chrome"--args in the terminal via the command line--disable-web-security

Chrome cross-domain settings after version number 49

After the version of Chrome has risen to 49, the cross-domain setting is stricter than before, and a directory of new user personal information needs to be given after the--disable-web-security is added to the command. It is well known that Chrome is a browser that needs to be signed in with a Gmail address, which will generate a directory where personal information is stored and personal information such as a user's collection, history, and so on. After version 49, if you set up a Chrome browser to support cross-domain mode, you need to specify a personal information directory, not the default directory, it is estimated that Chrome browser is afraid that users do not use cross-domain mode to disclose their personal information (mainly cookies, Many websites ' login token information is stored in a cookie.

Specific practices are:

1. Create a new directory on your computer, for example: C:\MyChromeDevUserData

2. Add the--disable-web-security--user-data-dir=c:\mychromedevuserdata,--user-data-dir value in the target input box in the Properties page to the new directory you just created.

3. Click Apply and OK to close the Properties page and open the Chrome browser.

Mac method:Chrome 48 cross-domain setting is stricter than before, want to cross the domain also need —user-data-dir to add

Launch the Chrome:open-a "Google Chrome"--args--disable-web-security--user-data-dir in the terminal via the command line (it is best to also add paths to the recommended paths below.) If not, use the no-add path)

Open Chrome again and find "--disable-web-security" related hints that chrome can work across domains again.

After the success of the cross-domain, the first page was replaced by Google's welcome pages, while the original collection of links and history are missing, and the C:\MyChromeDevUserData directory generates new personal information related files.

Reference: http://www.cnblogs.com/laden666666/p/5544572.html

Cross-domain settings for Windows & Mac Chrome-includes two settings, both before and after version 49

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.