Forum Moderators: coopster
I am sending visitors from my site to an external site through a redirect page on my site (redirect.php). When visitors come to my site, the 'id' parameter is set based on where they came from, and this is working properly. Redirect.php has the following code:
<?
$l = $_GET['l'];
$id = $_GET['id'];
$links = array();
$links['#*$!'] = 'http://www.example.com?id='.$_REQUEST['id'];
header('Location: '.$links[$l]);
exit();
?>
This sends my visitors to www.example.com, but does not correctly append the 'id' to the end of the URL. Is there a different way I should go about this?
Thanks,
Pede
[edited by: eelixduppy at 7:31 pm (utc) on Nov. 23, 2007]
Thank you for the reply and the welcome. Would the code you proposed only be applicable to 1 link? I have several links I would like to redirect in the same way with the id, so that was the reason for the array. I should have been more specific that my original post was an example that will apply to many links. If it will work for many links, that's great!
Thanks again for the assistance.
Pede