01-09-2008, 07:30 PM
|
#8 (permalink)
|
|
The Prestige
Join Date: Oct 2007
Location: Manchester, UK
Posts: 854
Thanks: 32
|
if its the classic 'headers already sent' error,then use an output buffer like so:
PHP Code:
ob_start(); //start the output buffer put at start of page
//do sum stuff
header('Location: login.php');
ob_flush(); //or ob_end_flush() if you want to close the buffer aswell as flush it
Just remember that inorder for anything to get back to the browser you must call:
ob_flush(); so that the buffer is flushed to the browser.
That should stop that error as it keeps all output in a temp 'buffer' so that when you flush it everything get sent at the same time thus solving the 'Headers already sent' error.
Hope that helps
__________________
mysql> SELECT * FROM `users` WHERE `users`.`clue` > 0;
Empty set (0.00 sec)
Last edited by sketchMedia : 01-09-2008 at 07:31 PM.
Reason: damn this new laptop keyboard
|
|
|
|