Session manager. Performs session managing function, such as variables deletion, initialisation and other session functions.
Definition at line 10 of file oxsession.php.
oxSession._allowSessionStart | ( | ) | [protected] |
Checks if we can start new session. Returns bool success status
Definition at line 872 of file oxsession.php.
oxSession._checkCookies | ( | $ | sCookieSid, | |
$ | aSessCookieSetOnce | |||
) | [protected] |
Check for existing cookie. Cookie info is dropped from time to time.
string | $sCookieSid coockie sid | |
array | $aSessCookieSetOnce if session cookie is set |
Definition at line 993 of file oxsession.php.
oxSession._checkSid | ( | ) | [protected] |
oxSession._checkUserAgent | ( | $ | sAgent, | |
$ | sExistingAgent | |||
) | [protected] |
Checking user agent
string | $sAgent current user agent | |
string | $sExistingAgent existing user agent |
Definition at line 944 of file oxsession.php.
oxSession._forceSessionStart | ( | ) | [protected] |
Returns true if its not search engine and config option blForceSessionStart = 1/true or _GET parameter "su" (suggested user id) is set.
Definition at line 862 of file oxsession.php.
oxSession._getBasketName | ( | ) | [protected] |
oxSession._getCookieSid | ( | ) | [protected] |
oxSession._getNewSessionId | ( | $ | blUnset = true |
) | [protected] |
Update the current session id with a newly generated one, deletes the old associated session file, frees all session variables.
bool | $blUnset if true, calls session_unset [optional] |
Definition at line 401 of file oxsession.php.
oxSession._getRequireSessionWithParams | ( | ) | [protected] |
returns configuration array with info which parameters require session start
Definition at line 1095 of file oxsession.php.
oxSession._getSessionUseCookies | ( | ) | [protected] |
return cookies usage for sid possibilities
Definition at line 1138 of file oxsession.php.
oxSession._initNewSessionChallenge | ( | ) | [protected] |
oxSession._isSessionRequiredAction | ( | ) | [protected] |
Tests if current action requires session
Definition at line 1115 of file oxsession.php.
oxSession._isSwappedClient | ( | ) | [protected] |
Saves various visitor parameters and compares with current data. Returns true if any change is detected. Using this method we can detect different visitor with same session id.
Definition at line 906 of file oxsession.php.
oxSession._isValidRemoteAccessToken | ( | ) | [protected] |
Checks if token supplied over 'rtoken' parameter match remote accecss session token.
Definition at line 1148 of file oxsession.php.
oxSession._sessionStart | ( | ) | [protected] |
Initialize session data (calls php.session_start())
Definition at line 310 of file oxsession.php.
oxSession._setSessionId | ( | $ | sSessId | ) | [protected] |
Sests session id to $sSessId
string | $sSessId sesion ID |
Definition at line 1039 of file oxsession.php.
oxSession._validateBasket | ( | oxBasket $ | oBasket | ) | [protected] |
Validate loaded from session basket content. Check for language change.
Definition at line 688 of file oxsession.php.
oxSession.checkSessionChallenge | ( | ) |
check for CSRF, returns true, if request (get/post) token maches session saved var false, if CSRF is possible
Definition at line 289 of file oxsession.php.
oxSession.delBasket | ( | ) |
static oxSession.deleteVar | ( | $ | name | ) | [static] |
Destroys a single element (passed to method) of an session array.
string | $name Name of parameter to destroy |
Definition at line 570 of file oxsession.php.
oxSession.deleteVariable | ( | $ | name | ) |
Destroys a single element (passed to method) of an session array.
string | $name Name of parameter to destroy |
Definition at line 582 of file oxsession.php.
oxSession.destroy | ( | ) |
Destroys all data registered to a session.
Definition at line 437 of file oxsession.php.
oxSession.freeze | ( | ) |
Ends the current session and store session data.
Definition at line 424 of file oxsession.php.
oxSession.getBasket | ( | ) |
oxSession.getBasketReservations | ( | ) |
return basket reservations handler object
Definition at line 1163 of file oxsession.php.
oxSession.getForcedName | ( | ) |
oxSession.getId | ( | ) |
static oxSession.getInstance | ( | ) | [static] |
get oxSession object instance (create if needed)
Definition at line 137 of file oxsession.php.
oxSession.getName | ( | ) |
oxSession.getRemoteAccessToken | ( | $ | blGenerateNew = true |
) |
Returns remote access key. With this key (called over "remotekey" URL parameter) and session id (sid parameter) you can access session from another client. The key is generated once per session after the first request.
bool | $blGenerateNew Should new token be generated |
Definition at line 844 of file oxsession.php.
oxSession.getRequestChallengeToken | ( | ) |
retrieve session challenge token from request
Definition at line 263 of file oxsession.php.
oxSession.getSessionChallengeToken | ( | ) |
retrieve session challenge token from session
Definition at line 273 of file oxsession.php.
static oxSession.getVar | ( | $ | name | ) | [static] |
IF available returns value of parameter, stored in session array.
string | $name Name of parameter |
Definition at line 530 of file oxsession.php.
oxSession.getVariable | ( | $ | name | ) |
IF available returns value of parameter, stored in session array.
string | $name Name of parameter |
Definition at line 542 of file oxsession.php.
static oxSession.hasVar | ( | $ | name | ) | [static] |
Checks if variable is set in session. Returns true on success.
string | $name Name to check |
Definition at line 453 of file oxsession.php.
oxSession.hasVariable | ( | $ | name | ) |
Checks if variable is set in session. Returns true on success.
string | $name Name to check |
Definition at line 465 of file oxsession.php.
oxSession.hiddenSid | ( | ) |
Forms input ("hidden" type) to pass session ID after submitting forms.
Definition at line 639 of file oxsession.php.
oxSession.initNewSession | ( | ) |
Assigns new session ID, clean existing data except persistent.
Definition at line 346 of file oxsession.php.
oxSession.isHeaderSent | ( | ) |
oxSession.isNewSession | ( | ) |
Indicates if setting of session id is executed in this script.
Definition at line 732 of file oxsession.php.
oxSession.isSessionStarted | ( | ) |
oxSession.isSidNeeded | ( | $ | sUrl = null |
) |
Checks if cookies are not available. Returns TRUE of sid needed
string | $sUrl if passed domain does not match current - returns true (optional) |
Definition at line 755 of file oxsession.php.
oxSession.processUrl | ( | $ | sUrl | ) |
Appends url with session ID, but only if oxSession._isSidNeeded() returns true Direct usage of this method to retrieve end url result is discouraged - instead see oxUtilsUrl.processUrl
string | $sUrl url to append with sid |
Definition at line 812 of file oxsession.php.
oxSession.regenerateSessionId | ( | ) |
oxSession.setBasket | ( | $ | oBasket | ) |
Sets basket session object.
object | $oBasket basket object |
Definition at line 710 of file oxsession.php.
oxSession.setForceNewSession | ( | ) |
Forces starting session and skips checking if session is allowed to start when calling oxSession.start();
Definition at line 743 of file oxsession.php.
oxSession.setId | ( | $ | sVal | ) |
Sets session id
string | $sVal id value |
Definition at line 159 of file oxsession.php.
oxSession.setName | ( | $ | sVal | ) |
Sets session param name
string | $sVal name value |
Definition at line 171 of file oxsession.php.
static oxSession.setVar | ( | $ | name, | |
$ | value | |||
) | [static] |
Sets parameter and its value to global session mixedvar array.
string | $name Name of parameter to store | |
mixed | $value Value of parameter |
Definition at line 491 of file oxsession.php.
oxSession.setVariable | ( | $ | name, | |
$ | value | |||
) |
Sets parameter and its value to global session mixedvar array.
string | $name Name of parameter to store | |
mixed | $value Value of parameter |
Definition at line 505 of file oxsession.php.
oxSession.sid | ( | $ | blForceSid = false |
) |
Returns string prefix to URL with session ID parameter. In some cases (if client is robot, such as Google) adds parameter shp, to identify, witch shop is currently running.
bool | $blForceSid forces sid getter, ignores cookie check (optional) |
Definition at line 608 of file oxsession.php.
oxSession.start | ( | ) |
Starts shop session, generates unique session ID, extracts user IP.
Definition at line 201 of file oxsession.php.
oxSession.$_aPersistentParams = array("actshop", "lang", "currency", "language", "tpllanguage") [protected] |
Definition at line 128 of file oxsession.php.
oxSession.$_aRequireSessionWithParams [protected] |
array( 'cl' => array ( 'register' => true, 'account' => true, ), 'fnc' => array ( 'tobasket' => true, 'login_noredirect' => true, 'tocomparelist' => true, ), '_artperpage' => true, 'ldtype' => true, 'listorderby' => true, )
Definition at line 101 of file oxsession.php.
oxSession.$_blForceNewSession = false [protected] |
Definition at line 63 of file oxsession.php.
oxSession.$_blIsNewSession = false [static, protected] |
Definition at line 37 of file oxsession.php.
oxSession.$_blNewSession = false [protected] |
Definition at line 56 of file oxsession.php.
oxSession.$_blSidNeeded = null [protected] |
Definition at line 121 of file oxsession.php.
oxSession.$_blStarted = false [protected] |
Definition at line 91 of file oxsession.php.
oxSession.$_instance = null [static, protected] |
Singleton instance keeper.
Definition at line 42 of file oxsession.php.
oxSession.$_oBasket = null [protected] |
Definition at line 77 of file oxsession.php.
oxSession.$_oBasketReservations = null [protected] |
Definition at line 84 of file oxsession.php.
oxSession.$_oUser = null [static, protected] |
Definition at line 48 of file oxsession.php.
oxSession.$_sErrorMsg = null [protected] |
Definition at line 70 of file oxsession.php.
oxSession.$_sForcedPrefix = 'force_' [protected] |
Definition at line 24 of file oxsession.php.
oxSession.$_sId = null [protected] |
Definition at line 30 of file oxsession.php.
oxSession.$_sName = 'sid' [protected] |
Definition at line 17 of file oxsession.php.