Thx a lot
This night I found a solution like yours
Code:
$liftdate=$time_unban;
$usergroupid=8;
$usertitle= "<font color=\"red\">Banned</font>";
$DB->query("
INSERT INTO " . TABLE_PREFIX . "userban
(userid, usergroupid, displaygroupid, customtitle, usertitle, adminid, bandate, liftdate)
VALUES
($user[userid], $user[usergroupid], $user[displaygroupid],'". addslashes($user['customtitle']) ."', '" . addslashes($user['usertitle']) . "', $bbuserinfo[userid], " . TIMENOW . ", $liftdate)");
$DB->query("
UPDATE " . TABLE_PREFIX . "user SET
usergroupid = $usergroupid,
displaygroupid = $usergroupid,
usertitle = '". addslashes($usertitle) . "'
WHERE userid = $user[userid]
");
This is the first time that I play with the code, I hope that everything will work.
Thanks still for the patience ^^