コード例 #1
0
 if (!$fullPowerLevelEditUser || $fullPower) {
     $ModifiedBy = $username;
 }
 if ($member) {
     $pending = 1;
 } else {
     $pending = 0;
 }
 $userQueries = new UserQueries();
 $user = $userQueries->getUserInfo($admin_banner);
 // Get add date of ban
 $addDate = $banQueries->getBanAddDate($banId);
 $lengthInSec = $length->getLengthInSeconds();
 $newExpireDate = $addDate + $lengthInSec;
 // Update ban
 $banQueries->updateWebBanWithLength($length->getLength(), $length->getTimeScale(), $newExpireDate, $reason, $pending, $admin_banner, $ModifiedBy, $serverId, $bannedUser, $user->getSteamId(), $banId, $comments, $bannedPost);
 // Email
 $subject = $LAN_PROCESSWEBBANUPDATE_001 . " " . $bannedUser . " " . $LAN_PROCESSWEBBANUPDATE_010 . " " . $username;
 $body = "<html><body><br/><h2>" . $subject . "</h2><br/><br/>";
 $body .= $LAN_PROCESSWEBBANUPDATE_002 . " <b>";
 if ($member) {
     $body .= $LAN_PROCESSWEBBANUPDATE_003;
 } else {
     if ($admin) {
         $body .= $LAN_PROCESSWEBBANUPDATE_004;
     } else {
         if ($banManager || $fullPower) {
             $body .= $LAN_PROCESSWEBBANUPDATE_005;
         }
     }
 }