Monday, July 7, 2008

To get IP Address

object obj = new object();


obj = Request.ServerVariables["HTTP_X_FORWARDED_FOR"];
if (obj == null)
{
obj = Request.ServerVariables["REMOTE_ADDR"];
}

No comments: