Posts: 31
Location: Simi Valley, CA
|
You could set the catch22 page on your server to an intermediate file (maybe referer-redirect.php) and then use $_SERVER['HTTP_REFERER'] to find the URL of the refering page. Then you can use the following to redirect to the page URL that you want:
PHP Code:
// save the referer path
$path = $_SERVER['HTTP_REFERER'];
$name= (manipulate path to get what you want)
// this redirects the page
header("Location: http://www.yoursite.com/blog.php?name=$name");
However, I should caution you that according to the PHP manual, 'HTTP_REFERER' "cannot be trusted." Try it out and see if it works!
Last edited by ademaskoo; 08-12-2005 at 11:09 PM..
Reason: typo
|