You are here

function hook_session_limit in Session Limit 6.2

Same name and namespace in other branches
  1. 7.2 session_limit.api.php \hook_session_limit()

Notify other modules that a session imitation event has occured.

When a session limit is reached, this hook is invoked. There are two types of event. Collision events happen when a new session causes an old session to close. Disconnect events happen when a new session is prevented by an existing session.

Parameters

string $sid: The session id of the session which caused the event. In a collision, this is not the session which was ended.

string $op: Either 'disconnect' or 'collision'.

4 functions implement hook_session_limit()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

rules_session_limit in ./session_limit.module
Implements hook_session_limit().
session_limit_invoke_session_limit in ./session_limit.module
Limit a users access to the sites based on the current session.
session_limit_session_limit in ./session_limit.module
Implements hook_session_limit().
trigger_session_limit in ./session_limit.module
Implements hook_session_limit().
1 invocation of hook_session_limit()
session_limit_invoke_session_limit in ./session_limit.module
Limit a users access to the sites based on the current session.

File

./session_limit.api.php, line 41
This file contains no working PHP code; it exists to provide additional documentation for doxygen as well as to document hooks in the standard Drupal manner.

Code

function hook_session_limit($sid, $op) {
  global $user;
  rules_invoke_event('session_limit_' . $op, $user, $sid);
}