C:/drupal/includes/session.inc File Reference

Go to the source code of this file.


Functions

 sess_open ($save_path, $session_name)
 sess_close ()
 sess_read ($key)
 sess_write ($key, $value)
 sess_regenerate ()
 sess_count ($timestamp=0, $anonymous=true)
 sess_destroy_sid ($sid)
 sess_destroy_uid ($uid)
 sess_gc ($lifetime)
 session_save_session ($status=NULL)


Detailed Description

User session handling functions.

Definition in file session.inc.


Function Documentation

sess_close (  ) 

Definition at line 13 of file session.inc.

sess_count ( timestamp = 0,
anonymous = true 
)

Counts how many users have sessions. Can count either anonymous sessions, authenticated sessions, or both.

Parameters:
int $timestamp A Unix timestamp representing a point of time in the past. The default is 0, which counts all existing sessions.
int $anonymous TRUE counts only anonymous users. FALSE counts only authenticated users. Any other value will return the count of both authenticated and anonymous users.
Returns:
int The number of users with sessions.

Definition at line 111 of file session.inc.

References db_query(), and db_result().

Here is the call graph for this function:

sess_destroy_sid ( sid  ) 

Called by PHP session handling with the PHP session ID to end a user's session.

Parameters:
string $sid the session id

Definition at line 122 of file session.inc.

References db_query().

Here is the call graph for this function:

sess_destroy_uid ( uid  ) 

End a specific user's session

Parameters:
string $uid the user id

Definition at line 132 of file session.inc.

References db_query().

Here is the call graph for this function:

sess_gc ( lifetime  ) 

Definition at line 136 of file session.inc.

References db_query().

Here is the call graph for this function:

sess_open ( save_path,
session_name 
)

Definition at line 9 of file session.inc.

sess_read ( key  ) 

Definition at line 17 of file session.inc.

References $result, db_fetch_object(), db_query(), drupal_anonymous_user(), and drupal_unpack().

Here is the call graph for this function:

sess_regenerate (  ) 

Called when an anonymous user becomes authenticated or vice-versa.

Definition at line 92 of file session.inc.

References db_query().

Here is the call graph for this function:

sess_write ( key,
value 
)

Definition at line 56 of file session.inc.

References $result, $value, db_query(), db_result(), ip_address(), session_save_session(), and variable_get().

Here is the call graph for this function:

session_save_session ( status = NULL  ) 

Determine whether to save session data of the current request.

This function allows the caller to temporarily disable writing of session data, should the request end while performing potentially dangerous operations, such as manipulating the global $user object. See for usage

Parameters:
$status Disables writing of session data when FALSE, (re-)enables writing when TRUE.
Returns:
FALSE if writing session data has been disabled. Otherwise, TRUE.

Definition at line 159 of file session.inc.

References $status.

Referenced by sess_write().


Generated on Mon Jun 2 15:08:08 2008 for SimpleTest by  1.5.5