How to do sub domain redirection with asp.net c#
string strServerName = Request.ServerVariables["SERVER_NAME"].ToString().ToUpper();
if (strServerName.IndexOf("subdomain1.domain.com") > -1)
{
Response.Redirect("/subdomain1");
}
else if ....
Sunday, 16 March 2008
Subscribe to:
Post Comments (Atom)
1 comment:
If you change it to upper case, you should check for upper case using instr (I think).
.ToUpper()
SUBDOMAIN1.DOMAIN.COM
http://www.nba-stats.com
Post a Comment