Get exclusive CAP network offers from top brands

View CAP Offers

Reply To: php question

[bsa_pro_ad_space id=2]
#779960
Anonymous
Inactive

Hi Erik,

Just some comments using your own code:

1) $url = “casino.php?ID=”.$_GET[ID];

It seems that it has no use in the part you sent.

2) If you are getting a 404, it is because the “header” has an invalid URL. So:

a) Since it is:
$row = mysql_fetch_object($result);
$row it is an array thus, it wouldnt work as you posted.
b) Should be:
header(‘Location: ‘.$row[0]);

3) There is an easy way to test what you are sending to the header. You print and ask the script to stop like this:
echo ‘URL: >’.$row[0].’<';
die;

4) You should close the database connection prior to the header redirection.

That is it.