<Table name="session">
<Column name="sessionid" type="string:64" primarykey="yes"/>
- <Column name="user" type="string:64" notnull="yes" foreignkey="user:uname"/>
+ <Column name="uname" type="string:64" notnull="yes" foreignkey="user:uname"/>
<!-- unix timestamp at which to delete this session -->
<Column name="timeout" type="int64" notnull="yes"/>
</Table>
$this->rights=array();
$this->flags=array();
$sid=$trans->getHeader("Wob-SessionId");
- $res=$db->select("session","sessionid,user","sessionid=".$db->escapeString($sid));
+ $res=$db->select("session","sessionid,uname","sessionid=".$db->escapeString($sid));
if(count($res)>0){
$this->sessid=$sid;
- $this->user=$res[0]["user"];
+ $this->user=$res[0]["uname"];
$this->initRights();
$this->initFlags($res[0]["flags"]);
}
$sid=getRandom(128);
}
$valid=time()+$ClientSessionTimeout;
- $ret=array("sessionid"=>$sid,"user"=>$trans->getusername(),"timeout"=>$valid);
+ $ret=array("sessionid"=>$sid,"uname"=>$trans->getusername(),"timeout"=>$valid);
$db->insert("session",$ret);
$db->commitTransaction();