header("Location: protected.php");

forgot the last part last time