本文整理匯總了PHP中users::getuserinfo方法的典型用法代碼示例。如果您正苦於以下問題:PHP users::getuserinfo方法的具體用法?PHP users::getuserinfo怎麽用?PHP users::getuserinfo使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類users
的用法示例。
在下文中一共展示了users::getuserinfo方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: admin_read
public function admin_read($ticket)
{
$users = new users();
if ($users->getuserinfo('user_group') == 1 && $this->ticket_info($ticket, 'user') != $_COOKIE['user']) {
$_link = $this->getDBH();
$query = $_link->prepare('UPDATE `tickets` SET `admin_read` = 1 WHERE `uniqid` = :uniqid');
$query->bindParam(':uniqid', $ticket, PDO::PARAM_STR);
$query->execute();
}
}
示例2: close_ticket
public function close_ticket($ticket)
{
$tickets = new tickets();
$users = new users();
$_link = $this->getDBH();
if ($tickets->is_ticket($ticket) && $users->getuserinfo('user_group') == 1) {
$query = $_link->prepare('UPDATE `tickets` SET `resolved` = 1 WHERE `uniqid` = :ticket');
$query->bindParam(':ticket', $ticket, PDO::PARAM_STR);
$query->execute();
echo 'success';
}
}