コード例 #1
0
                                                } else {
                                                    $main_content .= '
<TABLE BORDER="1" CELLSPACING="0" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="' . $config['site']['vdarkborder'] . '">
<TD CLASS="white"><b><center>Erro!</center></b></td>
</TR>
<TR BGCOLOR=' . $config['site']['darkborder'] . '>
<TD>
<center>Você não possui nenhum banimento em sua conta.</center>
</TD>
</TR>
</TABLE>
<br /><center><a href="?subtopic=shopsystem" border="0"><IMG SRC="' . $layout_name . '/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center><br /><br />';
                                                }
                                            } elseif ($buy_offer['type'] == 'storage') {
                                                $datadata = $SQL->query("SELECT * FROM  `player_storage` WHERE  `player_id` = " . $buy_player->getCustomField('id') . " AND  `key` = '" . $buy_offer['item_id'] . "'")->fetch();
                                                $player = $SQL->query("SELECT *  FROM `players` WHERE `id` = " . $buy_player->getCustomField('id') . "")->fetch();
                                                if ($datadata['key'] == $buy_offer['item_id']) {
                                                    $main_content .= '
<TABLE BORDER="1" CELLSPACING="0" CELLPADDING="4" WIDTH="100%">
<TR BGCOLOR="' . $config['site']['vdarkborder'] . '">
<TD CLASS=white><B><center>Erro!</center></B></TD>
</TR>
<TR BGCOLOR=' . $config['site']['darkborder'] . '>
<TD><center>Esse personagem já possui os Addons escolhidos.</center></TD>
</td>
</tr>
</TABLE>
<br />
';
                                                } else {
コード例 #2
0
ファイル: shopsystem.php プロジェクト: Alexzo20/gesior-aac
                                            $datadata = $SQL->query('SELECT * FROM ' . $SQL->tableName('bans') . ' WHERE value = ' . $my_acc_id . ';')->fetch();
                                            if ($datadata['value'] == $my_acc_id) {
                                                if ($SQL->query('DELETE FROM bans WHERE value= ' . $my_acc_id . ' LIMIT 1;')) {
                                                } else {
                                                    $SQL->query('DELETE FROM bans WHERE account= ' . $my_acc_id . ' LIMIT 1;');
                                                }
                                                $account_logged->setCustomField('premium_points', $user_premium_points - $buy_offer['points']);
                                                $user_premium_points = $user_premium_points - $buy_offer['points'];
                                                $main_content .= '<h2>Ban Deleted!</h2><b>Your account has been unbanned for ' . $buy_offer['points'] . ' premium points</b>from your account.
												<br>
												Now you have<b>' . $user_premium_points . ' premium points</b>.<br><a href="index.php?subtopic=shopsystem">GO TO MAIN SHOP SITE</a>';
                                            } else {
                                                $main_content .= '<b>You don\'t have any bans in your account!</b><br><a href="index.php?subtopic=shopsystem">GO BACK</a>';
                                            }
                                        } elseif ($buy_offer['type'] == 'itemlogout') {
                                            $my_acc_id = $buy_player->getCustomField('id');
                                            $datadata = $SQL->query('SELECT * FROM ' . $SQL->tableName('players') . ' WHERE id = ' . $my_acc_id . ';')->fetch();
                                            $datadata2 = $SQL->query('SELECT * FROM ' . $SQL->tableName('player_items') . ' WHERE player_id = ' . $my_acc_id . ';')->fetch();
                                            if ($datadata['online'] == '0') {
                                                if ($datadata2['pid'] != '10') {
                                                    if ($datadata['cap'] >= $SQL->quote($buy_offer['free_cap'])) {
                                                        $SQL->query('INSERT INTO player_items (player_id, pid, itemtype, count) VALUES (' . $my_acc_id . ', ' . $SQL->quote($buy_offer['pid']) . ', ' . $SQL->quote($buy_offer['item_id']) . ', ' . $SQL->quote($buy_offer['count1']) . ');');
                                                        $account_logged->setCustomField('premium_points', $user_premium_points - $buy_offer['points']);
                                                        $user_premium_points = $user_premium_points - $buy_offer['points'];
                                                        $main_content .= '<h2>Item received to player: ' . $buy_player->getName() . '!</h2><br>
															Now you have<b>' . $user_premium_points . ' premium points</b>.<br>
															<a href="index.php?subtopic=shopsystem">GO TO MAIN SHOP SITE</a>';
                                                    } else {
                                                        $main_content .= '<b>You need ' . $SQL->quote($buy_offer['free_cap']) . ' or more of cap!</b><br>
															<a href="index.php?subtopic=shopsystem">GO BACK</a>';
                                                    }