About the site navigation level two domain name problem, tangled for a long time

Source: Internet
Author: User
Tags vps
A problem has been tangled for a long time, a website, such as navigation has action comedy sci-fi

Corresponding to the two-level domain name, I use my station for example, not advertising,

The action is now: http://www.cuangs.com/Dongzuopian/should correspond to http://Dongzuopian.cuangs.com

Comedy is now: http://www.cuangs.com/Xijupian/should correspond to http://Xijupian.cuangs.com

Sci-Fi is now: http://www.cuangs.com/Kehuanpian/should correspond to http://Kehuanpian.cuangs.com

There must be a lot of love, suspense and so on behind.

I am not every level two to go to the corresponding binding, write here I have a bit dizzy, is the level two should be how to operate it? Online and so on.


Reply to discussion (solution)

It looks like you can rewrite it with a URL.

Your site http://www.cuangs.com does not support level two domain names
Please contact the domain name provider to open the two level domain name resolution

Your site http://www.cuangs.com does not support level two domain names
Please contact the domain name provider to open the two level domain name resolution


Support Oh, my is VPS, above has used two level of other stations

Learning and Learning

Have done similar, many regional sub-stations
If the standalone host does not bother, the level two domain name directly points to the root directory, the virtual host cannot save
Get a system variable at the entrance of the program, add in $_get,rewrite

Level two domain names are controlled by DNS providers, not VPS vendors, unless two are the same
Two level domain name sub-host and jump two ways, you this belongs to jump; Jump is also divided into explicit and non-explicit, depending on whether the DNS provider, it seems that many domestic DNS service providers do not support explicit jump
I don't know what's on the top of the wiki.

If supported, http://dongzuopian.cuangs.com should be able to access (even the wrong page) rather than prompt for a domain name error

Pan-Parse. This is really not done, the original is to win IIS directly a manual binding, that trouble Ah, Linux do not know how to operate.

There's no mystery, three steps.
1 Domain name to do a pan-resolution is *. Domain name and then individually bind a host header to the site
2 Obtaining the domain name currently accessed via the user's $_server[' http_host '
3 Obtain the user name based on the domain name you are currently accessing, and then get additional information.

Well, pan-resolution is OK, and according to $_server[' Http_host '] This combination can also, thank you, to fix.

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