【发布时间】:2013-09-03 22:51:12
【问题描述】:
以下代码:
WebRequest request = WebRequest.Create("http://localhost/sandbox/htmlpage1.htm");
WebResponse response = request.GetResponse();
string url = ((HttpWebResponse)response).ResponseUri.ToString();
正在请求 htmlpage1.html,而后者又重定向到另一个页面 (otherpage.htm?qs=data)。如何从 htmlpage1.htm 以编程方式重定向到的“其他页面”获取查询字符串。这是来自 winforms 应用程序的 LinkedIn OAuth2 例程。我需要 url 变量来给我 otherpage.htm 而不是 htmlpage1.htm 的查询字符串。任何帮助将不胜感激。
【问题讨论】:
标签: asp.net http oauth request