View Full Version : Header location messing up

06-04-2007, 03:49 AM
I am trying to do a header location.. but it is messing up .. it is giving me the following error

Cannot modify header information - headers already sent by (output started at /home/content/i/n/n/****/html/***/connect2.php:19)

I am using the following code

if($_SERVER['HTTP_REFERER'] =="http://profileawareness.com/forums"){

header("location: http://profileawareness.com/denied.html");

And it is giving an error in an included file (connect2.php), which all that has is some simple mysql querys (only 7 lines of code)

06-04-2007, 03:52 AM
Nothing can be outputted to the browser before a header is used unless you have output buffering turned on which probably isn't the best solution. Post the code for connect2.php leaving out your passwords and user names.