![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | Request.Url.GetLeftPart(UriPartial.Authority) - strange results I'm having a problem on an ASP.NET 1.1 web site. The page where I'm having a problem is accessed without SSL. It contains a link to another page which can be configured to require SSL. If SSL is required, I change the URL of the link from a relative URL to an absolute URL with HTTPS something like this: string newUrl = Request.Url.GetLeftPart(UriPartial.Authority).Replace("http://","https://") + Response.ApplyAppPathModifier("/MyApp/Secure/MyPage2.aspx"); The GetLeftPart(UriPartial.Authority) is returning a completely different domain name from the domain in the request: The Request address is like http://www.MyCompany.org/MyApp/Page1.aspx. The GetLeftPart expression is returning something like: https://www.MyCompanysOtherSite.org/...ure/Page2.aspx. If I enabling Trace for the www.MyCompany.org site, the trace information says the server variable SERVER_NAME is www.MyCompanysOtherSite.org . There is no reference in the application whatsoever to MyCompaniesOtherSite.org. So it appears to me that there's something incorrect in the setup of the MyCompany.org site, but this is beyond my expertise to explain or fix. How does GetLeftPart(UriPartial.Authority) work, is it the wrong concept here, what's happening? Tim W. |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| Strange request | Virtual PC | |||
| not enough authority | Vista account administration | |||
| Strange Vista Benchmark Results | Vista General | |||
| Help, Vista says I don't have Authority! | Vista General | |||
| Strange dir d*. results | Vista file management | |||