You are here

function securesite_user in Secure Site 5

Same name and namespace in other branches
  1. 6.2 securesite.module \securesite_user()
  2. 6 securesite.module \securesite_user()

Implementation of hook_user()

When users logout, show the HTTP Auth dialog to make sure the HTTP Auth credentials are cleared

See also

_securesite_user_auth()

File

./securesite.module, line 346
Secure Site contrib module

Code

function securesite_user($op, &$edit, &$user) {
  if ($op == 'logout' && variable_get('securesite_enabled', SECURESITE_DISABLED) == SECURESITE_AUTH && (isset($_SESSION['securesite_login']) ? $_SESSION['securesite_login'] : FALSE)) {

    // Load the anonymous user
    $user = drupal_anonymous_user();

    // Clear stored credentials
    _securesite_user_auth();
  }
}