Search All Articles Submit your Website or Blog to A New Internet Library
Tuesday, February 10, 2009
How to retrieve original request URL when using URL rewriting or Server.Transfer in ASP.NET.
The best way to retrieve original Request URL when URL rewriting is implemented is by using Request.ServerVariables("HTTP_X_REWRITE_URL")
This will work with all kinds of URL rewriting methods like using ISAPI filters, HTTP Handlers or Http Modules..
Before any URI modification original Request URI is saved into the HTTP header named X-Rewrite-URL.
And this can be retrieved in ASP.NET using Request.ServerVariables("HTTP_X_REWRITE_URL") alias.
Subscribe to:
Post Comments (Atom)
Also Read other Top Articles
- JSON Serialization in VS 2008
- Implementing Forms Authentication in Silverlight Application.
- Making GridView Rows or Individual Cells Clickable and Selectable.
- Enabling browser back button for GridView Paging and Sorting in Ajax 1.1 and 3.5 (using Visual Studio 2005/ Visual studio 2008)
- How to pass values from User Control to Page or calling Page methods from User Control.
- What is WCF?
- New features in C# 4.0
- C# to VB.NET and VB.NET to C# online free converter tools.


0 comments:
Post a Comment
Post your comments/questions/feedback for this Article.