How to make a subdomain point to a page in IIS7?

I have a website on IIS 7 and I created a subdomain and I want this subdomain to point to a page in this website.

Example:
www.example.com --> this is the main website and its default page is default.aspx
members.example.com --> I want if someone opening this url will forward to this page: www.example.com/members.aspx

How to setup this in my IIS 7?


Solution 1:

There are a couple of options including setting up a new site in IIS and pointing it to the directory/page you want, however the most widely accepted method would be to use URL rewrite rules to configure the subdomain. The steps to do so are a little in depth to lay out in all their glory here, but I am providing a link to the iis web team document detailing how to configure an IIS rewrite rule in IIS7, this should get you started down the correct path to configure what you need.