|
| initAttributes () |
|
| addUser () |
|
| isOssnUsername () |
|
| isOssnEmail () |
|
| getUser () |
|
| isPassword () |
|
| isEmail () |
|
| isUsername () |
|
| generateSalt () |
|
| setPassAlgo ($algo='') |
|
| getPassAlog () |
|
| verifyPassword ($password, $salt, $hash) |
|
| generate_password ($password='', $salt='') |
|
| Login () |
|
| update_last_login () |
|
| getFriendRequests ($user='') |
|
| isFriend ($usera, $user2) |
|
| getFriends ($user='', array $options=array()) |
|
| sendRequest ($from, $to) |
|
| requestExists ($from, $user) |
|
| deleteFriend ($from, $to) |
|
| getSiteUsers ($params=array()) |
|
| update_last_activity () |
|
| online_total () |
|
| getOnline ($intervals='100') |
|
| searchUsers (array $params=array()) |
|
| ValidateRegistration ($code) |
|
| iconURL () |
|
| profileURL ($extends='') |
|
| SendResetLogin () |
|
| resetPassword ($password) |
|
| deleteResetCode () |
|
| isOnline ($intervals=100) |
|
| deleteUser () |
|
| isUserVALIDATED () |
|
| resendValidationEmail () |
|
| getUnvalidatedUSERS ($search='', $count=false) |
|
| getProfilePhoto () |
|
| getProfileCover () |
|
| countByYearMonth () |
|
| getGenders () |
|
| genderTypes () |
|
| countByGender ($gender='male') |
|
| onlineByGender ($gender='male', $count=false, $intervals=100) |
|
| save () |
|
| canModerate () |
|
| isAdmin () |
|
| add () |
|
| get_entity () |
|
| save () |
|
| get_entities () |
|
| AddedEntityGuid () |
|
| updateEntity () |
|
| deleteByOwnerGuid ($guid, $type) |
|
| deleteEntity ($guid='') |
|
| searchEntities (array $params=array()) |
|
| canChange ($user='') |
|
| destruct () |
|
| __construct () |
|
| Connect () |
|
| insert ($params) |
|
| statement ($query) |
|
| execute ($values=array()) |
|
| update ($params=array()) |
|
| select ($params, $multi='') |
|
| fetch ($data=false) |
|
| delete ($params) |
|
| getLastEntry () |
|
| constructWheres (array $array, $operator="AND") |
|
| generateLimit ($data_limit=false, $page_limit=false, $offset=false) |
|
| clearVars () |
|
| __destruct () |
|
| getGUID () |
|
| getID () |
|
| getParam ($param) |
|
| isParam ($param) |
|
| __call ($method, $args) |
|
◆ addUser()
Add user to system.
- Returns
- boolean
◆ canModerate()
Can Moderate Check if user can moderate the requested item or not
- Returns
- boolean
◆ countByGender()
countByGender |
( |
|
$gender = 'male' | ) |
|
Get total users per month for each year
- Returns
- object|false @access public
◆ countByYearMonth()
Get total users per month for each year
- Returns
- object|false @access public
◆ deleteFriend()
deleteFriend |
( |
|
$from, |
|
|
|
$to |
|
) |
| |
Delete friend from list
- Returns
- boolean
◆ deleteResetCode()
Remove user reset code
- Returns
- boolean
◆ deleteUser()
Delete user from syste,
- Returns
- boolean
◆ genderTypes()
Gender types
- Returns
- object|false @access public
◆ generate_password()
generate_password |
( |
|
$password = '' , |
|
|
|
$salt = '' |
|
) |
| |
Generate password.
- Returns
- string
◆ generateSalt()
Generate salt.
- Returns
- string
◆ getFriendRequests()
getFriendRequests |
( |
|
$user = '' | ) |
|
Get user friends requests.
- Returns
- object
◆ getFriends()
getFriends |
( |
|
$user = '' , |
|
|
array |
$options = array() |
|
) |
| |
Get user friends.
- Returns
- object
◆ getGenders()
List existing Genders
- Returns
- array @access public
◆ getOnline()
getOnline |
( |
|
$intervals = '100' | ) |
|
Get online site users.
@params integer $intervals Seconds
- Returns
- object
◆ getPassAlog()
Get a password encryption algorithm
- Returns
- string
◆ getProfileCover()
Get a user last coverphoto photo
- Returns
- object|false
◆ getProfilePhoto()
Get a user last profile photo
- Returns
- object|false
◆ getSiteUsers()
getSiteUsers |
( |
|
$params = array() | ) |
|
Get site users.
- Parameters
-
array | $params | A options values |
- Note
- This method will be removed from Ossn v5
- Returns
- array
◆ getUnvalidatedUSERS()
getUnvalidatedUSERS |
( |
|
$search = '' , |
|
|
|
$count = false |
|
) |
| |
Get list of unvalidated users
- Returns
- false|object
◆ getUser()
Get user with its entities.
- Returns
- object
◆ iconURL()
View user icon url
- Returns
- string
◆ initAttributes()
Initialize the objects.
- Returns
- void
Reimplemented from OssnEntities.
◆ isAdmin()
isAdmin Check if user is admin or not
- Returns
- boolean
◆ isEmail()
Check if password is > 5 or not.
- Returns
- boolean
◆ isFriend()
isFriend |
( |
|
$usera, |
|
|
|
$user2 |
|
) |
| |
Check if the user is friend with other or not.
- Returns
- boolean
◆ isOnline()
isOnline |
( |
|
$intervals = 100 | ) |
|
Check if user is online or not
- Returns
- boolean
◆ isOssnEmail()
Check if email is exist in database or not.
- Returns
- boolean
◆ isOssnUsername()
Check if username is exist in database or not.
- Returns
- boolean
◆ isPassword()
Check if password is > 5 or not.
- Returns
- boolean
◆ isUsername()
Check if the user is correct or not.
- Returns
- boolean
◆ isUserVALIDATED()
Check if user is validated or not
- Returns
- boolean
◆ Login()
Login into site.
- Returns
- boolean
◆ Logout()
◆ online_total()
Count Total online site users.
- Returns
- boolean
◆ onlineByGender()
onlineByGender |
( |
|
$gender = 'male' , |
|
|
|
$count = false , |
|
|
|
$intervals = 100 |
|
) |
| |
Get online users by gender
- Parameters
-
string | $gender | Gender type |
boolean | $count | true or false |
integer | $intervals | Seconds |
- Returns
- object|false @access public
◆ profileURL()
profileURL |
( |
|
$extends = '' | ) |
|
View user profile url
- Returns
- string
◆ requestExists()
requestExists |
( |
|
$from, |
|
|
|
$user |
|
) |
| |
Check if the request already sent or not.
- Parameters
-
integer | $from | Relation from guid |
integer | $user | Relation to , user guid |
- Returns
- boolean
◆ resendValidationEmail()
resendValidationEmail |
( |
| ) |
|
Resend validation email to user
- Returns
- boolean
◆ resetPassword()
resetPassword |
( |
|
$password | ) |
|
Reset user password
- Returns
- boolean
◆ save()
Save a user entity
- Returns
- boolean
Reimplemented from OssnEntities.
◆ searchUsers()
searchUsers |
( |
array |
$params = array() | ) |
|
Search users using a keyword or entities_pairs
- Parameters
-
array | $params | A valid options in format: 'keyword' => A keyword to search users 'entities_pairs' => A entities pairs options, must be array 'limit' => Result limit default, Default is 10 values 'count' => True if you wanted to count search items. 'order_by' => To show result in sepcific order. Default is Assending |
reutrn array|false;
◆ sendRequest()
sendRequest |
( |
|
$from, |
|
|
|
$to |
|
) |
| |
Send request to other user.
- Returns
- boolean
◆ SendResetLogin()
Send user reset password link
- Returns
- boolean
◆ setLogin()
static setLogin |
( |
|
$userid | ) |
|
|
static |
login the user based on given input (by username, email, guid)
- Parameters
-
int | string | $user | A username, email, guid |
- Returns
- boolean
◆ setPassAlgo()
setPassAlgo |
( |
|
$algo = '' | ) |
|
Set a password encryption algorithm
- Parameters
-
string | $algo | algorithm name bcrypt/argon2i/md5 |
- Returns
- void
◆ update_last_activity()
Update user last activity time
- Returns
- boolean
◆ update_last_login()
Update user last login time.
- Returns
- boolean
◆ ValidateRegistration()
ValidateRegistration |
( |
|
$code | ) |
|
Validate User Registration
- Returns
- boolean
◆ verifyPassword()
verifyPassword |
( |
|
$password, |
|
|
|
$salt, |
|
|
|
$hash |
|
) |
| |
Verify a password
- Parameters
-
string | $password | New entered password |
string | $salt | User actual password salt |
string | $hash | Actual password |
- Returns
- boolean
The documentation for this class was generated from the following file:
- source/classes/OssnUser.php