Session taking its own sweet time to be Destroyed
<p>I have created a user page with a menu that contains a <strong>logout</strong> button. Upon clicking the button, the user is directed to a logout page with the following code:</p>

<pre><code>session_start();
session_destroy();

include("/var/www/include/header.inc");
echo "&lt;h&gt;Logout Success&lt;/h&gt;";
include("/var/www/include/menu.inc");
include("/var/www/include/footer.inc");
</code></pre>

<p>The code in the <strong>menu.inc</strong> file is written such that:</p>

<pre><code>if(@$_SESSION['login'] == "yes")
{
 // show expanded menu
}
else
{
 // show normal menu
}
</code></pre>

<p>What I am seeing now after logging out is the <strong>expanded menu</strong>. It seems that the menu is being included faster than the session can be destroyed, thus creating an impression that the user is still logged in. Is there a way to avoid such a situation?</p>
