Ahh - thanks - that's helped :-) (Line 9 was the http_referrer line)

Now the only trouble is, it seems to still treat $fred as null.

The passing line is from index.php:

<a href="redirect.php?fred=www.fusion.org.au">test link</a>

 Should this work?

Thanks,

Steve
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Steve Wade
Youth Outreach Coordinator
Fusion Australia Ltd (Sydney North)
ABN 26 001 273 105
+61 2 9477 1110


-----Original Message-----
From: Adaran (Marc E. Brinkmann) [mailto:[EMAIL PROTECTED]]
Sent: Thursday, 10 May 2001 22:20
To: [EMAIL PROTECTED]
Subject: Re[2]: [PHP] Newbie redirect/variable question


Hi Steve,

Thursday, May 10, 2001, 1:39:36 PM, you wrote:
Steve> Ok - thanks - my new redirect.php is

Steve> <?php
Steve> if ($fred != "") {
Steve> #     $statement = "UPDATE links SET hits=hits+1 WHERE href=\"$u\"";
Steve> #     mysql_query($statement);
Steve>     Header("Location: $fred");
Steve>     exit;
Steve> } else {
Steve>     Header("Location: $HTTP_REFERRER");
Steve>     exit;
Steve> }
?>>

Steve> I get the following message...
Steve> Warning: Cannot add header information - headers already sent by
(output
Steve> started at /home/swadie/public_html/redirect.php:2) in
Steve> /home/swadie/public_html/redirect.php on line 9

Make sure you have NO Blanks or any other Text before the <?php ! "<?" has
to be
the first two characters in the file. Which line is line 9 ?

-----------------------
EnjoY,
 Adaran ([EMAIL PROTECTED])
   check http://www.adaran.net



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to