function logout()
{
 var logout= confirm("Are you sure you want to logout?");
 if (logout== true)
 {
   window.location="logout.php";
 }
 else
 {
  window.location="#";
  }
}