I am developing an ASP.NET application. But i would like to hide the URL so user don't know on which page he or she standing. Is their any solution?
2 Answers
Use Server.Transfer . It doesn't change the URL.
Server.Transfer happens without the browser knowing anything, the browser request a page, but the server returns the content of another.
Server.Transfer() should be used when:
- we don't need to show the real URL where we redirected the request in the users Web Browser
- we want to transfer current page request to another .aspx page on the same server
- we want to preserve server resources and avoid the unnecessary roundtrips to the server
- we want to preserve Query String and Form Variables (optionally)
1 Comment
Sami
You can't hide the main URL like www.YourWebsite.com. Also replace all Response.Redirect with Server.Transfer
URL? From browser address bar? If it is what you are looking for, then No is the answer.. But you can try changing into differentrouteas explained in different way hereEncryptioninQuerystring