How do I implement a Bing-like access domain jump?

Source: Internet
Author: User
For example, when we visit Bing in China, Bing jumps to cn.bing.com
Excuse me: How to achieve similar bing access level two domain jump?

Reply content:

For example, when we visit Bing in China, Bing jumps to cn.bing.com
Excuse me: How to achieve similar bing access level two domain jump?

A lot of practical solutions to introduce two common to you:

  1. DNS resolution scheme, a lot of advanced DNS resolution can be resolved by the region (for example, Dnspod), as long as the resolution of the corresponding region into a jump on the line.
    The advantage is that soon, the disadvantage is not flexible

  2. program judgment, use IP to judge the source, and then jump in PHP, IP judgment source is very easy, many third-party IP interface can give out IP attribution.
    The advantage is very flexible, the disadvantage is that each request to the PHP processing area, performance to consider.

  3. Server judge, in fact, with the above is the same, nginx with a script to determine IP attribution, and then jump.
    Advantages quickly, shortcomings maintenance a little trouble

Use GeoIP or a ready-made IP API library.
Both Nginx and PHP have extensions.

  • 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.