Как получить “Хост”: заголовок от HttpContext (asp.net)

Я смог аутентифицировать против активного каталога, использующего пружинную безопасность 2.0.4.

я зарегистрировал настройки

http://maniezhilan.blogspot.com/2008/10/spring-security-204-with-active.html

10
задан Piotr Czapla 28 October 2009 в 17:14
поделиться

2 ответа

string requestedDomain = HttpContext.Current.Request.ServerVariables["HTTP_HOST"];
string requestScheme = HttpContext.Current.Request.Url.Scheme;
string requestQueryString = HttpContext.Current.Request.ServerVariables["QUERY_STRING"];
string requestUrl = HttpContext.Current.Request.ServerVariables["URL"];
17
ответ дан 3 December 2019 в 16:10
поделиться

HttpContext.Current.Request.Url.Host

6
ответ дан 3 December 2019 в 16:10
поделиться
Другие вопросы по тегам:

Похожие вопросы: