Typically for a logout page I use the following code...
<?php
if (!isset($_SESSION)) {
session_start();
}
?>
<?php
if ("" == ""){
// WA_ClearSession
$clearAll = TRUE;
$clearThese = explode(",","");
if($clearAll){
foreach ($_SESSION as $key => $value){
unset($_SESSION[$key]);
}
}
else{
foreach($clearThese as $value){
unset($_SESSION[$value]);
}
}
}
?>
The above code is usually pretty high on my page... Somewhere close to the first 2 or 3 lines. It will completely kill all of your session values. Which is what you want to have happen when you logout. I hope this helps.