title: How to terminate the user session in PHP?
body: <p>I have tracked the online user session with a img tag with the code below.</p>
  
  <pre><code>&lt;img src="http://www.somedomain.com/track/login.php" alt="" title="" width="1" height="1" /&gt;
  </code></pre>
  
  <p>Using the above code, I have made an administration section to display the online users.</p>
  
  <p>Now, due to some reason. I have to end the session of the online user from the administration section.</p>
  
  <p>Could anyone help me one this.</p>
  
  <p>Note:</p>
  
  <p>in users pages, User session is handled with</p>
  
  <pre><code>if(authenticated) {
   $_SESSION['username']=name;
   $_SESSION['id']=id;
  }
  </code></pre>