mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-10-10 11:02:41 +00:00
- added function to set user id in session (currently not used)
This commit is contained in:
parent
9ccca2261d
commit
8e950290dc
|
@ -147,6 +147,22 @@ class LetoDMS_Session {
|
||||||
return $this->id;
|
return $this->id;
|
||||||
} /* }}} */
|
} /* }}} */
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set user of session
|
||||||
|
*
|
||||||
|
* @param integer $userid id of user
|
||||||
|
*/
|
||||||
|
function setUser($userid) { /* {{{ */
|
||||||
|
/* id is only set if load() was called before */
|
||||||
|
if($this->id) {
|
||||||
|
$queryStr = "UPDATE tblSessions SET userID = " . $this->db->qstr($userid) . " WHERE id = " . $this->db->qstr($this->id);
|
||||||
|
if (!$this->db->getResult($queryStr))
|
||||||
|
return false;
|
||||||
|
$this->data['userid'] = $userid;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
} /* }}} */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set language of session
|
* Set language of session
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue
Block a user