Page 1 of 1

PHP Redirect

Posted: Sun Sep 24, 2006 4:22 pm
by dclamp
I have a PHP page on my domain: http://dclamp.homtek.net/invite.php.

i have it redirect to this page: http://www.rapidfriends.com/join_inv.php?member_id=94 only.

I want it so that some one can put there ID in my domain and have it put it at the end. like this:

They Visit: http://dclamp.homtek.net/invite.php?ID=91

and it redirects to: http://www.rapidfriends.com/join_inv.php?member_id=91

how do i do this?

Posted: Sun Sep 24, 2006 4:39 pm
by s.dot

Code: Select all

if(!empty($_GET['id']) && is_numeric($_GET['id']))
{
   header('Location: http://www.domain.com/page.php?id='.$_GET['id']);
} else
{
   header('Location: http://www.domain.com/page.php');
}
:wink: