本文整理汇总了PHP中misc::scanTiebaByUser方法的典型用法代码示例。如果您正苦于以下问题:PHP misc::scanTiebaByUser方法的具体用法?PHP misc::scanTiebaByUser怎么用?PHP misc::scanTiebaByUser使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类misc
的用法示例。
在下文中一共展示了misc::scanTiebaByUser方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: foreach
case 'showtb':
if (isset($_GET['set'])) {
$x = $m->fetch_array($m->query('SELECT * FROM `' . DB_NAME . '`.`' . DB_PREFIX . TABLE . '` WHERE `uid` = ' . UID . ' LIMIT 1'));
$f = $x['tieba'];
foreach ($_POST['no'] as $k => $x) {
$id = intval($k);
if ($x == '0') {
$xv = '0';
} else {
$xv = '1';
}
$m->query("UPDATE `" . DB_PREFIX . TABLE . "` SET `no` = '{$xv}' WHERE `id` = '{$id}' AND `uid` = '" . UID . "' ;");
}
Redirect('index.php?mod=showtb&ok');
} elseif (isset($_GET['ref'])) {
$r = misc::scanTiebaByUser();
Redirect('index.php?mod=showtb');
} elseif (isset($_GET['clean'])) {
CleanUser(UID);
Redirect('index.php?mod=showtb');
} elseif (isset($_GET['del'])) {
$id = (int) sqladds($_REQUEST['id']);
$m->query('DELETE FROM `' . DB_NAME . '`.`' . DB_PREFIX . TABLE . '` WHERE `id` =' . $id);
Redirect('index.php?mod=showtb&ok');
} elseif (isset($_GET['reset'])) {
$max = $m->fetch_array($m->query("select max(id) as id from `" . DB_NAME . "`.`" . DB_PREFIX . TABLE . "` where `uid`=" . UID));
$min = $m->fetch_array($m->query("select min(id) as id from `" . DB_NAME . "`.`" . DB_PREFIX . TABLE . "` where `uid`=" . UID));
$max = $max['id'];
$min = $min['id'];
while ($min < $max) {
$res = $m->fetch_array($m->query('SELECT * FROM `' . DB_NAME . '`.`' . DB_PREFIX . TABLE . '` WHERE `id` =' . $min . ' Limit 1'));