$playerName = 'Planet Reporter'; } if ($sender_id == -1) { $playerName = 'Bank Reporter'; } if ($sender_id == -2) { $playerName = 'Forces Reporter'; } if ($sender_id == -3) { $playerName = 'Game Admins'; } } $threads[$i]['Sender'] = $playerName; $db2->query('SELECT * FROM player_has_alliance_role JOIN alliance_has_roles USING(game_id,alliance_id,role_id) WHERE account_id = ' . $db->escapeNumber($player->getAccountID()) . ' AND game_id = ' . $db->escapeNumber($player->getGameID()) . ' AND alliance_id=' . $db->escapeNumber($alliance->getAllianceID()) . ' LIMIT 1'); $db2->nextRecord(); $threads[$i]['CanDelete'] = $player->getAccountID() == $sender_id || $db2->getBoolean('mb_messages'); if ($threads[$i]['CanDelete']) { $container['thread_id'] = $threadID; $threads[$i]['DeleteHref'] = SmrSession::getNewHREF($container); } $threads[$i]['Replies'] = $db->getInt('num_replies'); $thread_replies[$i] = $db->getInt('num_replies'); $threads[$i]['SendTime'] = $db->getInt('sendtime'); ++$i; } $container = create_container('skeleton.php', 'alliance_message_view.php'); $container['alliance_id'] = $alliance->getAllianceID(); $container['thread_ids'] = $thread_ids; $container['thread_topics'] = $thread_topics; $container['thread_replies'] = $thread_replies; $container['alliance_eyes'] = $alliance_eyes;
$PHP_OUTPUT .= '<tr>'; $PHP_OUTPUT .= '<th>ID</th>'; $PHP_OUTPUT .= '<th>Login</th>'; $PHP_OUTPUT .= '<th>eMail</th>'; $PHP_OUTPUT .= '<th>Action</th>'; $PHP_OUTPUT .= '</tr>'; while ($db->nextRecord()) { $db2->query('SELECT * FROM account WHERE password = '******'password'))); while ($db2->nextRecord()) { $curr_account_id = $db2->getField('account_id'); $db3->query('SELECT * FROM account_is_closed WHERE account_id = ' . $db->escapeNumber($curr_account_id) . ' LIMIT 1'); $isDisabled = $db3->getNumRows() > 0; $PHP_OUTPUT .= '<tr' . ($isDisabled ? ' class="red"' : '') . '>'; $PHP_OUTPUT .= '<td>' . $db2->getField('account_id') . '</td>'; $PHP_OUTPUT .= '<td>' . $db2->getField('login') . '</td>'; $PHP_OUTPUT .= '<td' . ($db2->getBoolean('validated') ? '' : ' style="text-decoration:line-through;"') . '>' . $db2->getField('email') . ' (' . ($db2->getBoolean('validated') ? 'Valid' : 'Invalid') . ')</td>'; $PHP_OUTPUT .= '<td align="center"><input type="checkbox" name="disable_account[]" value="' . $curr_account_id . '"'; // check if this guy is maybe already disabled $db3->query('SELECT * FROM account_is_closed WHERE account_id = ' . $db->escapeNumber($curr_account_id)); if ($isDisabled) { $PHP_OUTPUT .= ' checked'; } else { if ($action == 'Select All') { $PHP_OUTPUT .= ' checked'; } } $PHP_OUTPUT .= '></td>'; $PHP_OUTPUT .= '</tr>'; } $PHP_OUTPUT .= '<tr>'; $PHP_OUTPUT .= '<td colspan="3"> </td>';
$PHP_OUTPUT .= 'Enter the account id of the entry you wish to edit:'; $PHP_OUTPUT .= create_echo_form(create_container('skeleton.php', 'album_moderate.php')); $PHP_OUTPUT .= '<input type="number" name="account_id" size="5" id="InputFields" class="center"> '; $PHP_OUTPUT .= create_submit('Submit'); $PHP_OUTPUT .= '</form>'; $PHP_OUTPUT .= $error_msg; } else { // check if input is numeric if (!is_numeric($account_id)) { create_error('Please enter an account ID, which has to be numeric!'); } // check if the givin account really has an entry if ($account_id > 0) { $db->query('SELECT * FROM album WHERE account_id = ' . $db->escapeNumber($account_id) . ' AND Approved = \'YES\''); if ($db->nextRecord()) { $disabled = $db->getBoolean('disabled'); $location = stripslashes($db->getField('location')); $email = stripslashes($db->getField('email')); $website = stripslashes($db->getField('website')); $day = $db->getField('day'); $month = $db->getField('month'); $year = $db->getField('year'); $other = nl2br(stripslashes($db->getField('other'))); } else { $account_id = 0; $error_msg = '<div align="center" class="red bold">This User doesn\'t have an album entry or it needs to be approved first!</div>'; } } $container = create_container('album_moderate_processing.php', ''); $container['account_id'] = $account_id; $PHP_OUTPUT .= '<table border="0" align="center" cellpadding="5" cellspacing="0">';