Creating Subdomains Programmatically
问题 I am looking for a solution to create subdomains programmatically in ASP.NET, ASP.NET MVC and PHP. Specifically, a user profile page should resolve for both: www.domain.com/profilename or http://profilename.domain.com . 回答1: Update your DNS settings of the particular domain so that *.domain.com all point to the same host. Then, programmatically check and see if the first part of the URL used contains the subdomain you are looking for, and act accordingly. For example, if the first part