próbowałem:Jak przekierować do katalogu głównego aplikacji za pomocą modułu do przepowiadania adresów URL IIS7?
1) Próbowałem pusty ciąg pierwszy:
<action type="Redirect" url="" redirectType="Permanent" appendQueryString="false" />
Wynik:
HTTP 500.52 - URL Rewrite Module Error.
The substitution URL for the current action cannot be empty.
2) Może powinienem pominąć atrybut url
:
<action type="Redirect" redirectType="Permanent" appendQueryString="false" />
Ten sam wynik:
HTTP 500.52 - URL Rewrite Module Error.
The substitution URL for the current action cannot be empty.
3) Co o sposobie ASP.NET:
<action type="Redirect" url="~" redirectType="Permanent" appendQueryString="false" />
Próbuje przekierować do {APP_ROOT}/~
.
4) Ostatnia próba:
<action type="Redirect" url="/" redirectType="Permanent" appendQueryString="false" />
Zgodnie z oczekiwaniami, to przekierowuje do katalogu głównego serwera ...
Chciałbym znaleźć jakieś rozwiązanie czystej rodzajowe. (. Nie mogę korzystać z niektórych beton /myCurrentAppPath
)
+1 Ok. Dziękuję Ci. –