Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to redirect to last visited page 2

Status
Not open for further replies.

Jaheel22

Technical User
Jul 14, 2004
84
US
How to redirect a user to the last visted page after the user is logged in ? Any alternative besides session variables ? Thanks much
 
Use the http referrer attribute to get the page that calls your login page
 
Something like:
Dim x As HttpRequest
Response.Write(x.UrlReferrer)
 
Also, there is a javascript method you can use (history.go(-1)) but remember not all users might have javascript capabilities.

Also, the Referrer isn't always passed through so you'll have to check it exists first.


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top