Ell20 Posted April 4, 2008 Share Posted April 4, 2008 Hi, I keep getting this error on my script and I have no idea why: 0.010.01 Warning: Cannot modify header information - headers already sent by (output started at pointy/scpoints.php:239) in /pointy/scpoints.php on line 280 Warning: Cannot modify header information - headers already sent by (output started at pointy/scpoints.php:239) in pointy/scpoints.php on line 455 Line 280:}else{header('Location:pointsback.php');} Line 455: header("Location:../pointsback.php"); Appreciate any help Quote Link to comment Share on other sites More sharing options...
maexus Posted April 4, 2008 Share Posted April 4, 2008 http://www.phpfreaks.com/forums/index.php/topic,37442.0.html "HEADER ERRORS - READ HERE BEFORE POSTING THEM" It's stickied right at the top of the forum, in all caps. Quote Link to comment Share on other sites More sharing options...
kenrbnsn Posted April 4, 2008 Share Posted April 4, 2008 Read the sticky note above Ken Quote Link to comment Share on other sites More sharing options...
bryan52803 Posted April 4, 2008 Share Posted April 4, 2008 Because you're attempting to modify the header information after HTML (or otherwise content) is written. 1. Edit your post and remove the /home/... parts of the error; the less you reveal about your site file hierarchy the better. Knowledgeable people can do bad things with even the slightest hint of information like that. 2. Check your code before header() is called. Is anything echoed, printed, or otherwise output to the browser? This is your problem. Bryan Quote Link to comment Share on other sites More sharing options...
Ell20 Posted April 4, 2008 Author Share Posted April 4, 2008 Nothing is output to the browser in the whole script. Im working on the IPN script for paypal. There is no white space and there is no HTML in the file at all. Cheers Quote Link to comment Share on other sites More sharing options...
bryan52803 Posted April 4, 2008 Share Posted April 4, 2008 Please paste this line of code "scpoints.php line 239" (assuming there's no sensitive data) Note also that whitespace in any include's and require's will affect this as well Bryan Quote Link to comment Share on other sites More sharing options...
kenrbnsn Posted April 4, 2008 Share Posted April 4, 2008 According the the error message output started at pointy/scpoints.php:239 it's saying that the output started at line 239 of the file pointy/scpoints.php That's where you have to look. Ken Quote Link to comment Share on other sites More sharing options...
Ell20 Posted April 4, 2008 Author Share Posted April 4, 2008 Line 239 of scpoints.php is: echo $payment_gross; Thanks for the help Quote Link to comment Share on other sites More sharing options...
kenrbnsn Posted April 4, 2008 Share Posted April 4, 2008 The echo statement is sending output to the screen. Ken Quote Link to comment Share on other sites More sharing options...
Ell20 Posted April 4, 2008 Author Share Posted April 4, 2008 I just commented the line out as it was useless anyway. I think its fixed. Thanks for your help! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.