harish - 2011-03-30 07:52:55
if(isset($_SESSION['msg'])&& !empty($_SESSION['msg'])){
echo '<script type="text/javascript">alert("'.$msg.'")</script>';
unset($_SESSION['msg']);
}
I have this code used in the index file. The problem is that the message whatever stored in session is not alerted even the first time page loads after the session variable is declared. If i comment the third line then it works, but i need to unset the session variable after it is alerted. Help me what may be the possible caused for the problem.
Thanks
Harish