/** * Обновить запись о пользователе * * @param string $name Имя пользователя * @param string $surname Фамилия пользователя * @param integer $type Тип * @param string $mess Сообщение * @param integer $uid ИД Пользотеля * @return boolean true - если все прошло успешно, иначе false */ function Update($name, $surname, $type, $mess, $uid) { if (confa07::CheckUid($uid)) { $sql = "UPDATE confa07 SET name='{$name}',surname='{$surname}',type=" . intval($type) . ",message='{$mess}' where uid='{$uid}'"; pg_query(DBConnect(), $sql); return true; } return false; }
header('Location: /404.php'); exit; } if (!is_admin_sm()) { exit; } $action = trim($_GET['action']); switch ($action) { case 'delete': $id = trim($_GET['id']); if ($id) { $error = confa07::Delete($id); } break; } $users = confa07::GetAll(); ?> <strong>Пользователи</strong><br><br> <br><br> <table width="100%" border="0" cellspacing="2" cellpadding="2"> <?php $i = 0; if ($users) { foreach ($users as $ikey => $user) { ++$i; ?> <tr class="qpr"> <td> <table width="100%" cellspacing="0" cellpadding="0" border="0"> <tr valign="top" class="n_qpr">