How can I detect if a URL is redirected to another one?
问题 I use this code to make a 'GET' request to urls. var request = WebRequest.Create(uri) as HttpWebRequest; request.Method = "GET"; var response = request.GetResponse() as HttpWebResponse; var status = response.StatusCode; // returns HttpStatusCode.OK So, the probelem is when a url is redirected to another one, I can't detect it. For example; url is: http://site.com that redirects to http://www.site.com but when I make a request to http://site.com it returns a HttpStatusCode.OK for it -instead