Changeset 130 for www/user.php
- Timestamp:
- Jan 5, 2009, 7:35:58 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
www/user.php
r77 r130 20 20 var $DefaultRole = 2; 21 21 var $AnonymousUserId = 1; 22 22 23 23 function Check() 24 24 { … … 39 39 $Query = $this->Database->select('UserOnline', '*', 'SessionId="'.$SID.'"'); 40 40 $Row = $Query->fetch_array(); 41 if( $Row['User'] != $this->AnonymousUserId)41 if(($Row['User'] != $this->AnonymousUserId) and ($Query->num_rows > 0)) 42 42 { 43 43 $Query = $this->Database->select('User', '*', "Id=".$Row['User'].""); 44 44 $this->User = $Query->fetch_array(); 45 45 $Result = USER_LOGGED; 46 } else 46 } else 47 47 { 48 48 $Query = $this->Database->select('User', '*', "Id=".$this->AnonymousUserId); … … 54 54 // Role and permission 55 55 $this->LoadRoles(); 56 57 56 } 58 57
Note:
See TracChangeset
for help on using the changeset viewer.