Parašė Lordcraft· 2008 Rugs. 22 21:09:01
#16
man neiaisku kodel po to laiko as nepalieku tos grupes: ten tas if kur sakai tai cia turbut butu toks kodas kuris rasosi i setuser.php faila:
$dabar = time();
$vev_result = dbquery(
"SELECT * FROM `".$db_prefix."users` WHERE `gr_time_left`<'".$dabar."' AND `user_groups`='.1'");
$vev_rows = dbrows ($vev_result);
if ($vev_rows > 0) {
$vev_list = "";
for ($vev_i = 0; $vev_i < $vev_rows; $vev_i ++) {
$vev_row = dbarray ($vev_result);
$vev_list = $vev_list . "," . $vev_row ["user_id"];
}
dbquery (
"UPDATE " . $db_prefix . "users SET user_groups = REPLACE(user_groups, '.1', '') WHERE user_id IN (0" . $vev_list . ")");
}
$result = dbquery("DELETE FROM ".$db_prefix."online WHERE online_user='0' AND online_ip='".USER_IP."'");