<PHP
// insert into DB
if (headers_sent())
{
echo "<html><head><meta http-equiv=\"refresh\" content=\"0; URL=index.php\"></head><body>";
echo "<a href=\"index.php\">Main</a></body></html>";
}
else header("Location: index.php");
?>
header("Location page.php"); is the funtion you search,
the other stuff helps sometimes, when PHP claims, that
there have been headers sent, although they haven't
another possibility would be to compare timestamps, the one
of the user's last post and his new post, if the diff. is less than
10 sec, it's probably done by accident