I have got a php code down below and i want it to have that if the statement if false, it will go to a page automatically.
Whenever i am using the "header" function, i get an error "Cannot modify header information - headers already sent by...."
<?php
if(empty($_SESSION['pass']))
{
echo "U bent niet ingelogt.";
echo '<form action="index.php" method="post">';
echo 'Code <input type="text" name="code">';
echo '<input type="submit">';
echo '</form>';
}
else {
// Go automatically to a page;
}
?>