if($logs['uid']) {
$nums = renum($logs['uid']);
foreach ($nums[0] as $num) {
$_SGLOBAL['db']->query("UPDATE ".tname('space')." SET viewnum=viewnum+$num WHERE uid IN (".simplode($nums[1][$num]).")");
}
}
if($logs['uid']) {
$nums = renum($logs['uid']);
foreach ($nums[1] as $key=>$num) {
$_SGLOBAL['db']->query("UPDATE ".tname('space')." SET viewnum=viewnum+$key WHERE uid IN (".simplode($num).")");