Hi guys,
I have a problem of redirecting, and this is part of my script where the error occurs:
<?
if ($login == 'Ok')
{
?>
<HTML><HEAD><TITLE>You're Logged In!</TITLE></HEAD>
<BODY><CENTER>Congratulation You're logged in</CENTER></BODY></HTML>
<?
}
header ("Location: UserControlPanel.php"
?>
It gave me the following error:
Warning: Cannot add header information - headers already sent by (output started at /path/to/the/file/login.php:120) in /path/to/the/file/login.php on line 182
I want it to work just like how it's working in any forum when you login to the forum, it redirect to a temp page telling you "Thank you for login" and then redirect to the forum sections or your control panel. How can I do something like this?
I have a problem of redirecting, and this is part of my script where the error occurs:
<?
if ($login == 'Ok')
{
?>
<HTML><HEAD><TITLE>You're Logged In!</TITLE></HEAD>
<BODY><CENTER>Congratulation You're logged in</CENTER></BODY></HTML>
<?
}
header ("Location: UserControlPanel.php"
?>
It gave me the following error:
Warning: Cannot add header information - headers already sent by (output started at /path/to/the/file/login.php:120) in /path/to/the/file/login.php on line 182
I want it to work just like how it's working in any forum when you login to the forum, it redirect to a temp page telling you "Thank you for login" and then redirect to the forum sections or your control panel. How can I do something like this?