Forum Moderators: coopster
<?php
session_start();
ob_start();
$page_title = "Some Other Page";
// Authorization check
if (!isset($_SESSION['USERPASS']))
{
$redirect_url = "index.php";
header("Location: $redirect_url");
}
ob_end_flush;
?>
I have read that the ob_end_flush; isn't needed: That PHP.ini automatically executes it if a ob_start() was called. Is this true? If so, can including it in the script anyway cause problems? I was just curious. Thank's in advance for you opinion! :0)
-- Zak
So what will happen if you ob_end_flush()? You will diplay all the data stored in that buffer.
So to clean the buffer and write the data out use ob_end_flush() and if you don't want to show any errors use ob_end_clean()
More about it is in [php.net...]
Best regards
Michal Cibor
[us4.php.net...]
This is more of a curiousity issue than functionality ...
-- Zak