PHP Class Users, phprs-restful

Mostra file Open project: caoym/phprs-restful Class Usage Examples

Public Properties

Property Type Description
$db PDO
$oss

Public Methods

Method Description
createUser ( &$uid, $token, $account, $alias, $password, $avatar = null ) : user's create user
deleteUserByAccount ( $account )
getCurrentUser ( $token ) get current user info
getUserByAccount ( $account )
getUserByAlias ( $alias )
getUserByIds ( $uids, $asDict = false ) get users info
updateUser ( $token, $alias = null, $password = null, $avatar = null ) modify user's information
verifyPassword ( $account, $password )

Private Methods

Method Description
getUser ( $cond )
uploadAvatar ( $file )

Method Details

createUser() public method

create user
public createUser ( &$uid, $token, $account, $alias, $password, $avatar = null ) : user's
return user's

deleteUserByAccount() public method

public deleteUserByAccount ( $account )

getCurrentUser() public method

get current user info
public getCurrentUser ( $token )

getUserByAccount() public method

public getUserByAccount ( $account )

getUserByAlias() public method

public getUserByAlias ( $alias )

getUserByIds() public method

get users info
public getUserByIds ( $uids, $asDict = false )

updateUser() public method

modify user's information
public updateUser ( $token, $alias = null, $password = null, $avatar = null )

verifyPassword() public method

public verifyPassword ( $account, $password )

Property Details

$db public_oe property

public PDO $db
return PDO

$oss public_oe property

public $oss