Asp. NET provides a powerful Web. config to configure the site, in general, a Web site has only one root directory of the Web. config file, sometimes we want subdirectories with different permissions or parameter settings, you can add a Web. config
Use Linux shared host, control surface version is Cpanel's friends know that he default binding the primary domain name root directory is public_html
So if you want to put the domain name yourdomain.com can directly access, it is necessary to all
When we install the Forum or blog on the virtual host, we will install it in a folder under the root directory (Www/web directory) for ease of management, for example, I install a discuz forum, I will create a new BBS directory under the root
The directory structure of the Web site is:
# tree/home/wwwroot/exehack.net/home/wwwroot/exehack.net├──bbs│└──index.html└──www└──index.html2 directories, 2 files
/home/wwwroot/exehack.net is the path to the default source code for the Nginx
This article mainly introduces the PHP level two subdirectory (background directory) to set the level two domain name method. Have a good reference value, follow the small series together to see it
We can use Apache's. htaccess rewrite to
Tools/MaterialsLinux Virtual Host. htaccess fileFor Windows hosts, you need to configure the Httpd.ini file to bind subdirectories, and for Linux hosts, you need to configure the. htaccess file.It may be easier to understand this by example, such as
Most virtual hosts cannot modify the root directory of a Web site. Can be achieved through. htaccess. Apache host general support. Htaccess pseudo-static, that can be implemented to bind the domain name to subdirectories, a space multiple
WebLogic the process of creating a domain is simple, but it is important to be aware that domain names cannot exist before you create domains.Domain is simply defined as: is a logical management unit, the domain under the bread with WebLogic
Rewriteengine onRewritebase/# Change the www.jb51.net to the domain you want to bind.# If it is a domain name: Rewritecond%{http_host} ^ ((Www|blog) \.)? jb51\.net$Rewritecond%{http_host} ^ ((Www|blog) \.)? 127.0.0.1$# change WWW to the directory
Loading and Writing moduleLoadModule rewrite_module modules/mod_rewrite.soAdd configurationThe third line above has an absolute path, which is used to map subdirectories, depending on what directory is dependent on the server.Restart Apache service
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.