Forums

This topic is locked

Login - Redirect Problem (ASP/VBScript)

Posted 16 Jun 2005 21:01:49
1
has voted
16 Jun 2005 21:01:49 Bari Samad posted:
Hello:

I am using the built in login behaviour in Dreamweaver as well as a registration page and it works great if the user is trying to access the site from the main page index.asp. The successful login redirects to index.asp.

The Problem:

This is a database driven site that has a "tell a friend" component which sends a page with URL parameters to a specific asp page. The dynamic asp page traps for login which is fine BUT on successful registration or login the user is sent to index.asp.

They loose the data page they were sent which kinda defeats the purpose huh! They could re-click their link because now the session variable is set but that is assuming too much.

Is there a way to code into the login and registration pages that if the user came from index.asp ... fine send them there but if they came from a link, they should be re-directed there?

Thanks in advance.

Bari

Replies

Replied 29 Jun 2005 14:12:29
29 Jun 2005 14:12:29 Simon Bloodworth replied:
hi

try using the- Request.ServerVariables("HTTP_REFERER" - in the redirect to page bit on the login - this should hopefully send them back to the page that they came from.

cheers

Simon

DWMX 2004 | ASP | VBScript

Reply to this topic