Thursday, August 9, 2007

Header redirect

<?php
header("location:/yourfile.php");
// replace yourfile.php with your filename
?>

Headers Already Sent is a problem many people have. To solve this:

<?php
// Run ob_start
ob_start();

//Your script here

//Run ob_end_flush
ob_end_flush();
?>

No comments: