PHP: session variables are overwritten by declared variables with same name
<p>Just now verified that, PHP session variable is overwritten by declared variable with same name. i.e) I have session variable <code>$_SESSION['lan'] = 'xyz'</code> (global variable) and one of my PHP page x.php having variable <code>$lan</code> in <code>foreach</code> loop, at end of this loop my <code>$_SESSION['lan']</code> is overwritten by last value of the array which is used in foreach loop.</p>

<p>I mean <code>$_SESSION['lan']</code> having value 'abc' and that lan <code>$_SESSION</code> global variable became 'abc' hereafter.</p>
