You use the "Bindings..." option In IIS7 for configuring the domain/subdomain for each website.
This is a way you could set it up:
Make sure you have two websites in IIS7. One is set to the root of your website directory, another one set to the root directory of your blog platform.
Your website has the binding configured like this: www.mydomain.com using Port 80
The blog site has the binding configured like this: blog.mydomain.com using Port 80
这基本上是做什么的,它将名称与不同的网站关联起来,这样当请求到达同一 IP 上的服务器时,IIS 就知道将请求分派到哪个网站。
IIS 中的默认网站由于没有主机名,因此将处理所有非 www 或 blog 子域的请求。
Q1: yes
Q2: Create two websites, ignore the default web site. One for www and the other for blog. On the new website screen specify the Host Name accordingly, i.e. www.mydomain.com for the first site and blog.mydomain.com for the second. Keep the port 80 for both. Later you can change these settings in the website Bindings screen.
What this basically does it associates names with different websites so when requests come to your server on the same IP IIS knows to which website to dispatch the request.
The default website in IIS, because it has no Host Name, will handle all the requests that are neither for www or blog subdomains.
发布评论
评论(2)
是的,这是可以实现的。
您可以使用 IIS7 中的“绑定...”选项来配置每个网站的域/子域。
这是一种设置方法:
使用端口 80 的 www.mydomain.com
使用端口 80 的 blog.mydomain.com
Yes, this can be accomplished.
You use the "Bindings..." option In IIS7 for configuring the domain/subdomain for each website.
This is a way you could set it up:
www.mydomain.com using Port 80
blog.mydomain.com using Port 80
Q1:是
Q2:创建两个网站,忽略默认网站。一个用于 www,另一个用于博客。在新网站屏幕上相应地指定主机名,即第一个站点为 www.mydomain.com,第二个站点为 blog.mydomain.com。保留两者的端口 80。稍后您可以在网站绑定屏幕中更改这些设置。
这基本上是做什么的,它将名称与不同的网站关联起来,这样当请求到达同一 IP 上的服务器时,IIS 就知道将请求分派到哪个网站。
IIS 中的默认网站由于没有主机名,因此将处理所有非 www 或 blog 子域的请求。
Q1: yes
Q2: Create two websites, ignore the default web site. One for www and the other for blog. On the new website screen specify the Host Name accordingly, i.e. www.mydomain.com for the first site and blog.mydomain.com for the second. Keep the port 80 for both. Later you can change these settings in the website Bindings screen.
What this basically does it associates names with different websites so when requests come to your server on the same IP IIS knows to which website to dispatch the request.
The default website in IIS, because it has no Host Name, will handle all the requests that are neither for www or blog subdomains.