Page is a not externally linkable
- Code, Content, and Presentation
-- PHP Server Side Scripting
---- Redirect user to previous page after logging in


scraptoft - 9:18 pm on Sep 16, 2009 (gmt 0)


Hi d40sithui thanks for your help, I just did a quick search and this is what I came up with.

Hows this sound? Am I on the right track?

session_start();
$_SESSION['referer'] = $_SERVER['HTTP_REFERER'];

$referer = $_SESSION['referer'];

and then:
header("Location:$referer");

I can't test it right now, will do so in the morning.


Thread source:: http://www.webmasterworld.com/php/3990391.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com