You are here

protected function SessionProxy_Backend_Native::getSessionUid in Session Proxy 7

Get the actual logged in user user identifier if any.

Return value

int Valid user identifier or NULL.

Overrides SessionProxy_Backend_Base::getSessionUid

File

lib/SessionProxy/Backend/Native.php, line 11

Class

SessionProxy_Backend_Native
Native implementation of session backend: use PHP native session handling. Using it allows to use built-in extensions session handling, such as Redis or Memcache extensions features, which are known to be really fast.

Code

protected function getSessionUid() {
  return isset($_SESSION['uid']) ? $_SESSION['uid'] : NULL;
}