function drupal_save_session in Zircon Profile 8.0
Same name and namespace in other branches
- 8 modules/memcache/unstable/memcache-session.inc \drupal_save_session()
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 http://drupal.org/node/218104 for usage
Parameters
$status: Disables writing of session data when FALSE, (re-)enables writing when TRUE.
Return value
FALSE if writing session data has been disabled. Otherwise, TRUE.
3 calls to drupal_save_session()
- drupal_session_commit in modules/
memcache/ unstable/ memcache-session.inc - Commit the current session, if necessary.
- MemcacheSessionTestCase::testSessionSaveRegenerate in modules/
memcache/ tests/ memcache-session.test - Tests for drupal_save_session() and drupal_session_regenerate().
- _drupal_session_write in modules/
memcache/ unstable/ memcache-session.inc - Write a session to session storage.
File
- modules/
memcache/ unstable/ memcache-session.inc, line 320
Code
function drupal_save_session($status = NULL) {
$save_session =& drupal_static(__FUNCTION__, TRUE);
if (isset($status)) {
$save_session = $status;
}
return $save_session;
}