web/wp-content/plugins/wp-native-php-sessions/callbacks.php
/**
 * Writes an entire session to the database (internal use only).
 *
 * This function is registered with session_set_save_handler() to support
 * database-backed sessions.
 *
 * This function is an internal function and must not be called directly.
 * Doing so may result in corrupted session data or other unexpected behavior.
 * Session data must always be accessed via the $_SESSION superglobal.
 *
 * @param $sid The session ID of the session to write to.
 * @param $value Session data to write as a serialized string.
 * @return boolean
 */
Writes an entire session to the database (internal use only).
This function is registered with session_set_save_handler() to support
database-backed sessions.

This function is an internal function and must not be called directly.
Doing so may result in corrupted session data or other unexpected behavior.
Session data must always be accessed via the $_SESSION superglobal.

@param $sid The session ID of the session to write to.
@param $value Session data to write as a serialized string.
@return boolean
Writes an entire session to the database ( internal use only ) . This function is registered with session_set_save_handler () to support database - backed sessions . This function is an internal function and must not be called directly . Doing so may result in corrupted session data or other unexpected behavior . Session data must always be accessed via the $_SESSION superglobal . @param $sid The session ID of the session to write to . @param $value Session data to write as a serialized string . @return boolean
function _pantheon_session_write( $sid, $value ) {
	$session = \Pantheon_Sessions\Session::get_by_sid( $sid );
	if ( ! $session ) {
		$session = \Pantheon_Sessions\Session::create_for_sid( $sid );
	}
	if ( ! $session ) {
		trigger_error( 'Could not write session to the database. Please check MySQL configuration.', E_WARNING );
		return false;
	}
	$session->set_data( $value );
	return true;
}
function _pantheon_session_write ( $ sid , $ value ) { $ session = \ Pantheon_Sessions \ Session :: get_by_sid ( $ sid ) ; if ( ! $ session ) { $ session = \ Pantheon_Sessions \ Session :: create_for_sid ( $ sid ) ; } if ( ! $ session ) { trigger_error ( 'Could not write session to the database. Please check MySQL configuration.' , E_WARNING ) ; return false ; } $ session -> set_data ( $ value ) ; return true ; }
Writes an entire session to the database (internal use only).
Writes an entire session to the database ( internal use only ) .