当前位置: 首页>>代码示例>>PHP>>正文


PHP char_get_level_color函数代码示例

本文整理汇总了PHP中char_get_level_color函数的典型用法代码示例。如果您正苦于以下问题:PHP char_get_level_color函数的具体用法?PHP char_get_level_color怎么用?PHP char_get_level_color使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了char_get_level_color函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: get_map_ppl

function get_map_ppl($id, &$sqlm)
{
    require_once 'char_lib.php';
    $map_ppl = $sqlm->fetch_assoc($sqlm->query('
		SELECT number_pl
		FROM dbc_map
		WHERE id=' . $id . ' LIMIT 1'));
    return char_get_level_color($map_ppl['number_pl']);
}
开发者ID:BACKUPLIB,项目名称:minimanager-1,代码行数:9,代码来源:map_zone_lib.php

示例2: sel_char

function sel_char()
{
    global $output, $action_permission, $characters_db, $realm_id, $user_id, $sql, $core;
    valid_login($action_permission["view"]);
    $output .= '
          <div id="xname_fieldset" class="fieldset_border center">
            <span class="legend">' . lang("unstuck", "selectchar") . '</span>
            <span class="xname_info">' . lang("unstuck", "info") . '</span>
            <br />
            <br />
            <form method="get" action="hearthstone.php" id="form">
              <div>
                <input type="hidden" name="action" value="approve" />
              </div>
              <table class="lined" id="xname_char_table">
                <tr>
                  <th class="xname_radio">&nbsp;</th>
                  <th class="xname_name">' . lang("unstuck", "char") . '</th>
                  <th class="xname_LRC">' . lang("unstuck", "lvl") . '</th>
                  <th class="xname_LRC">' . lang("unstuck", "race") . '</th>
                  <th class="xname_LRC">' . lang("unstuck", "class") . '</th>
                </tr>';
    if ($core == 1) {
        $chars = $sql["char"]->query("SELECT * FROM characters WHERE acct='" . $user_id . "'");
    } else {
        $chars = $sql["char"]->query("SELECT * FROM characters WHERE account='" . $user_id . "'");
    }
    while ($char = $sql["char"]->fetch_assoc($chars)) {
        $output .= '
                <tr>
                  <td>
                    <input type="radio" name="char" value="' . $char["guid"] . '" ' . ($char["online"] != 0 ? 'disabled="disabled"' : '') . ' />
                  </td>
                  <td>' . $char["name"] . '</td>
                  <td>' . char_get_level_color($char["level"]) . '</td>
                  <td>
                    <img src="img/c_icons/' . $char["race"] . '-' . $char["gender"] . '.gif" onmousemove="toolTip(\'' . char_get_race_name($char["race"]) . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" />
                  </td>
                  <td>
                    <img src="img/c_icons/' . $char["class"] . '.gif" onmousemove="toolTip(\'' . char_get_class_name($char["class"]) . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" />
                  </td>
                </tr>';
    }
    $output .= '
                <tr>
                  <td colspan="5" class="hidden">';
    makebutton(lang("unstuck", "selectchar"), "javascript:do_submit()", 180);
    $output .= '
                  </td>
                </tr>
              </table>
            </form>
          </div>
          <br />';
}
开发者ID:Refuge89,项目名称:World-of-Warcraft-Trinity-Core-MaNGOS,代码行数:55,代码来源:hearthstone.php

示例3: view_guild

function view_guild()
{
    global $lang_guild, $lang_global, $output, $realm_db, $characters_db, $mmfpm_db, $realm_id, $itemperpage, $action_permission, $user_lvl, $user_id, $showcountryflag;
    if (!isset($_GET['id'])) {
        redirect("guild.php?error=1&amp;realm={$realmid}");
    }
    $sqlr = new SQL();
    $sqlr->connect($realm_db['addr'], $realm_db['user'], $realm_db['pass'], $realm_db['name']);
    if (empty($_GET['realm'])) {
        $realmid = $realm_id;
    } else {
        $realmid = $sqlr->quote_smart($_GET['realm']);
        if (!is_numeric($realmid)) {
            $realmid = $realm_id;
        }
    }
    $sqlc = new SQL();
    $sqlc->connect($characters_db[$realmid]['addr'], $characters_db[$realmid]['user'], $characters_db[$realmid]['pass'], $characters_db[$realmid]['name']);
    $guild_id = $sqlc->quote_smart($_GET['id']);
    if (is_numeric($guild_id)) {
    } else {
        redirect("guild.php?error=6&amp;realm={$realmid}");
    }
    //==========================SQL INGUILD and GUILDLEADER======================
    $q_inguild = $sqlc->query("select 1 from guild_member where guildid = '{$guild_id}' and guid in (select guid from characters where account = '{$user_id}')");
    $inguild = $sqlc->result($q_inguild, 0, '1');
    if ($user_lvl < $action_permission['update'] && !$inguild) {
        redirect("guild.php?error=6&amp;realm={$realmid}");
    }
    $q_amIguildleader = $sqlc->query("select 1 from guild where guildid = '{$guild_id}' and leaderguid in (select guid from characters where account = '{$user_id}')");
    $amIguildleader = $sqlc->result($q_amIguildleader, 0, '1');
    $q_guildmemberCount = $sqlc->query("SELECT 1 from guild_member where guildid = '{$guild_id}'");
    $guildmemberCount = $sqlc->num_rows($q_guildmemberCount);
    //====================SQL INGUILD and GUILDLEADER end========================
    //==========================$_GET and SECURE=================================
    $start = isset($_GET['start']) ? $sqlc->quote_smart($_GET['start']) : 0;
    if (is_numeric($start)) {
    } else {
        $start = 0;
    }
    $order_by = isset($_GET['order_by']) ? $sqlc->quote_smart($_GET['order_by']) : "mrank";
    if (!preg_match("/^[_[:lower:]]{1,10}\$/", $order_by)) {
        $order_by = "mrank";
    }
    $dir = isset($_GET['dir']) ? $sqlc->quote_smart($_GET['dir']) : 1;
    if (!preg_match("/^[01]{1}\$/", $dir)) {
        $dir = 1;
    }
    $order_dir = $dir ? "ASC" : "DESC";
    $dir = $dir ? 0 : 1;
    //==========================$_GET and SECURE end=============================
    $query = $sqlc->query("SELECT guildid, name, info, MOTD, createdate,\r\n    (select count(*) from guild_member where guildid = '{$guild_id}') as mtotal,\r\n    (select count(*) from guild_member where guildid = '{$guild_id}' and guid in\r\n    (select guid from characters where online = 1)) as monline\r\n    FROM guild WHERE guildid = '{$guild_id}'");
    $guild_data = $sqlc->fetch_row($query);
    $output .= "\r\n<center>\r\n\t<div id=\"tab_content\">\r\n\t\t<div id=\"tab\">\r\n\t\t\t<ul>\r\n\t\t\t\t<li id=\"selected\"><a href=\"guild.php?action=view_guild&amp;realm={$realmid}&amp;error=3&amp;id={$guild_data['0']}\">" . $lang_guild['members'] . "</a></li>\r\n\t\t\t\t<li><a href=\"guildbank.php?id={$guild_id}&amp;realm={$realmid}\">" . $lang_guild['guildbank'] . "</a></li>\r\n\t\t\t</ul>\r\n\t\t</div>\r\n";
    $output .= "\r\n        <script type=\"text/javascript\">\r\n          answerbox.btn_ok='{$lang_global['yes']}';\r\n          answerbox.btn_cancel='{$lang_global['no']}';\r\n        </script>\r\n\t\t<div id=\"tab_content2\">\r\n\t\t\t<table class=\"hidden\" style=\"width: 100%;\">\r\n              <tr>\r\n                <td>\r\n                  <table class=\"lined\"style=\"width: 100%;\">\r\n                    <tr>\r\n                      <td width=\"25%\"><b>{$lang_guild['create_date']}:</b><br />" . date('o-m-d', $guild_data[4]) . "</td>\r\n                      <td width=\"50%\" class=\"bold\">{$guild_data['1']}</td>\r\n                      <td width=\"25%\"><b>{$lang_guild['tot_m_online']}:</b><br />{$guild_data['6']} / {$guild_data['5']}</td>\r\n                    </tr>";
    if ($guild_data[2] != '') {
        $output .= "\r\n                    <tr>\r\n                      <td colspan=\"3\"><b>{$lang_guild['info']}:</b><br />{$guild_data['2']}</td>\r\n                    </tr>";
    }
    if ($guild_data[3] != '') {
        $output .= "\r\n                    <tr>\r\n                      <td colspan=\"3\"><b>{$lang_guild['motd']}:</b><br />{$guild_data['3']}</td>\r\n                    </tr>";
    }
    $output .= "\r\n                  </table>\r\n                </td>\r\n              </tr>\r\n              <tr>\r\n                <td align=\"right\">" . generate_pagination("guild.php?action=view_guild&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by={$order_by}&amp;dir=" . ($dir ? 0 : 1) . "", $guildmemberCount, $itemperpage, $start) . "</td>\r\n              </tr>\r\n              <tr>\r\n                <td>\r\n                  <table class=\"lined\" style=\"width: 100%;\">\r\n                    <tr>\r\n                      <th width=\"1%\">{$lang_guild['remove']}</th>\r\n                      <th width=\"20%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=cname&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'cname' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['name']}</a></th>\r\n                      <th width=\"1%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=crace&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'crace' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['race']}</a></th>\r\n                      <th width=\"1%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=class&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'cclass' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['class']}</a></th>\r\n                      <th width=\"1%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=clevel&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'clevel' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['level']}</a></th>\r\n                      <th width=\"23%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=mrank&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'mrank' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['rank']}</a></th>\r\n                      <th width=\"25%\">{$lang_guild['pnote']}</th>\r\n                      <th width=\"25%\">{$lang_guild['offnote']}</th>\r\n                      <th width=\"1%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=clogout&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'clogout' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['llogin']}</a></th>\r\n                      <th width=\"1%\"><a href=\"guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by=conline&amp;start={$start}&amp;dir={$dir}\">" . ($order_by == 'conline' ? "<img src=\"img/arr_" . ($dir ? "up" : "dw") . ".gif\" alt=\"\" /> " : "") . "{$lang_guild['online']}</a></th>";
    if ($showcountryflag) {
        require_once 'libs/misc_lib.php';
        $sqlm = new SQL();
        $sqlm->connect($mmfpm_db['addr'], $mmfpm_db['user'], $mmfpm_db['pass'], $mmfpm_db['name']);
        $output .= "\r\n                      <th width=\"1%\">{$lang_global['country']}</th>";
    }
    $output .= "\r\n                    </tr>";
    $members = $sqlc->query("SELECT gm.guid as cguid, c.name as cname, c.`race` as crace ,c.`class` as cclass,\r\n    c.`level` AS clevel,\r\n    gm.rank AS mrank, (SELECT rname FROM guild_rank WHERE guildid ='{$guild_id}' AND rid = mrank) AS rname,\r\n    gm.Pnote, gm.OFFnote, gender,\r\n    c.`online` as conline, c.`account`, c.`logout_time` as clogout\r\n    FROM guild_member as gm left outer join characters as c on c.guid = gm.guid\r\n    WHERE gm.guildid = '{$guild_id}' ORDER BY {$order_by} {$order_dir} LIMIT {$start}, {$itemperpage}");
    while ($member = $sqlr->fetch_row($members)) {
        $result = $sqlr->query("SELECT gmlevel FROM account WHERE id ='{$member['11']}'");
        $owner_gmlvl = $sqlr->result($result, 0, 'gmlevel');
        $output .= "\r\n                    <tr>";
        // gm, gildleader or own account! are allowed to remove from guild
        $output .= $user_lvl >= $action_permission['delete'] || $amIguildleader || $member[11] == $user_id ? "\r\n                      <td>\r\n                        <img src=\"img/aff_cross.png\" alt=\"\" onclick=\"answerBox('{$lang_global['delete']}: &lt;font color=white&gt;{$member[1]}&lt;/font&gt;&lt;br /&gt;{$lang_global['are_you_sure']}', 'guild.php?action=rem_char_from_guild&amp;realm={$realmid}&amp;id={$member['0']}&amp;guld_id={$guild_id}');\" style=\"cursor:pointer;\" />\r\n                      </td>" : "\r\n                      <td>\r\n                      </td>";
        $output .= $user_lvl < $owner_gmlvl ? "\r\n                      <td>" . htmlentities($member[1]) . "</td>" : "\r\n                      <td><a href=\"char.php?id={$member['0']}&amp;realm={$realmid}\">" . htmlentities($member[1]) . "</a></td>";
        $output .= "\r\n                      <td><img src='img/c_icons/{$member[2]}-{$member[9]}.gif' onmousemove='toolTip(\"" . char_get_race_name($member[2]) . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\" /></td>\r\n                      <td><img src='img/c_icons/{$member[3]}.gif' onmousemove='toolTip(\"" . char_get_class_name($member[3]) . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\" /></td>\r\n                      <td>" . char_get_level_color($member[4]) . "</td>\r\n                      <td>" . htmlentities($member[6]) . " (" . $member[5] . ")</td>\r\n                      <td>" . htmlentities($member[7]) . "</td>\r\n                      <td>" . htmlentities($member[8]) . "</td>\r\n                      <td>" . get_days_with_color($member[12]) . "</td>\r\n                      <td>" . ($member[10] ? "<img src=\"img/up.gif\" alt=\"\" />" : "-") . "</td>";
        if ($showcountryflag) {
            $country = misc_get_country_by_account($member[11], $sqlr, $sqlm);
            $output .= "\r\n                      <td>" . ($country['code'] ? "<img src='img/flags/" . $country['code'] . ".png' onmousemove='toolTip(\"" . $country['country'] . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\" />" : "-") . "</td>";
        }
        $output .= "\r\n                    </tr>";
    }
    unset($member);
    $output .= "\r\n                  </table>\r\n                </td>\r\n              </tr>\r\n              <tr>\r\n                <td align=\"right\">" . generate_pagination("guild.php?action=view_guild&amp;error=3&amp;realm={$realmid}&amp;id={$guild_id}&amp;order_by={$order_by}&amp;dir=" . !$dir, $guildmemberCount, $itemperpage, $start) . "</td>\r\n              </tr>\r\n            </table>\r\n\t\t</div>\r\n\t</div>\r\n            <br />";
    $output .= "\r\n            <table class=\"hidden\">\r\n              <tr>\r\n                <td>";
    if ($user_lvl >= $action_permission['delete'] || $amIguildleader) {
        makebutton($lang_guild['del_guild'], "guild.php?action=del_guild&amp;realm={$realmid}&amp;id={$guild_id}\" type=\"wrn", 130);
        $output .= "\r\n                </td>\r\n                <td>";
    }
    makebutton($lang_guild['show_guilds'], "guild.php?realm={$realmid}\" type=\"def", 130);
    $output .= "\r\n                </td>\r\n              </tr>\r\n            </table>\r\n\t</center>\r\n";
}
开发者ID:brunogcar,项目名称:minimanager,代码行数:94,代码来源:guild.php

示例4: edit_user


//.........这里部分代码省略.........
            $banned[3] = "";
        }
        if ($user_lvl >= $action_permission['update']) {
            $output .= "\r\n                <td><input type=\"checkbox\" name=\"banned\" value=\"1\" {$ban_checked}/>{$ban_info}</td>";
        } else {
            $output .= "\r\n                <td>{$ban_info}</td>";
        }
        $output .= "\r\n              </tr>\r\n              <tr>\r\n                <td>{$lang_user['banned_reason']}</td>";
        if ($user_lvl >= $action_permission['update']) {
            $output .= "\r\n                <td><input type=\"text\" name=\"banreason\" size=\"42\" maxlength=\"255\" value=\"{$banned['3']}\" /></td>";
        } else {
            $output .= "\r\n                <td>{$banned['3']}</td>";
        }
        if ($expansion_select) {
            $output .= "\r\n              </tr>\r\n              <tr>";
            if ($user_lvl >= $action_permission['update']) {
                $output .= "\r\n                <td>{$lang_user['client_type']}</td>";
                $output .= "\r\n                <td>\r\n                  <select name=\"expansion\">";
                $output .= "\r\n                    <option value=\"0\">{$lang_user['classic']}</option>\r\n                    <option value=\"1\" ";
                if ($data['expansion'] == 1) {
                    $output .= "selected=\"selected\" ";
                }
                $output .= ">{$lang_user['tbc']}</option>\r\n                   <option value=\"2\" ";
                if ($data['expansion'] == 2) {
                    $output .= "selected=\"selected\" ";
                }
                $output .= ">{$lang_user['wotlk']}</option>\r\n                  </select>\r\n                </td>";
            } else {
                $output .= "\r\n                <td>{$lang_user['classic']}</td>";
            }
        }
        $output .= "\r\n              </tr>\r\n              <tr>\r\n                <td>{$lang_user['failed_logins_long']}</td>";
        if ($user_lvl >= $action_permission['update']) {
            $output .= '
                <td><input type="text" name="failed" size="42" maxlength="3" value="' . $data['failed_logins'] . '" /></td>';
        } else {
            $output .= '
                <td>' . $data['failed_logins'] . '</td>';
        }
        $output .= "\r\n              </tr>\r\n              <tr>\r\n                <td>{$lang_user['locked']}</td>";
        $lock_checked = $data['locked'] ? " checked=\"checked\"" : "";
        if ($user_lvl >= $action_permission['update']) {
            $output .= "\r\n                <td><input type=\"checkbox\" name=\"locked\" value=\"1\" {$lock_checked}/></td>";
        } else {
            $output .= "\r\n                <td></td>";
        }
        $output .= '
              </tr>
              <tr>
                <td>' . $lang_user['last_login'] . '</td>
                <td>' . $data['last_login'] . '</td>
              </tr>
              <tr>
                <td>' . $lang_user['online'] . '</td>';
        $output .= "\r\n                <td>" . ($data['active_realm_id'] ? $lang_global['yes'] : $lang_global['no']) . "</td>\r\n              </tr>";
        $query = $sqlr->query("SELECT SUM(numchars) FROM realmcharacters WHERE acctid = '{$id}'");
        $tot_chars = $sqlr->result($query, 0);
        $query = $sqlc->query("SELECT count(*) FROM `characters` WHERE account = {$id}");
        $chars_on_realm = $sqlc->result($query, 0);
        $output .= "\r\n              <tr>\r\n                <td>{$lang_user['tot_chars']}</td>\r\n                <td>{$tot_chars}</td>\r\n              </tr>";
        $realms = $sqlr->query("SELECT id, name FROM realmlist");
        if ($developer_test_mode && $multi_realm_mode && ($sqlr->num_rows($realms) > 1 && count($server) > 1 && count($characters_db) > 1)) {
            require_once "scripts/get_lib.php";
            while ($realm = $sqlr->fetch_array($realms)) {
                $sqlc->connect($characters_db[$realm[0]]['addr'], $characters_db[$realm[0]]['user'], $characters_db[$realm[0]]['pass'], $characters_db[$realm[0]]['name']);
                $query = $sqlc->query("SELECT count(*) FROM `characters` WHERE account = {$id}");
                $chars_on_realm = $sqlc->result($query, 0);
                $output .= "\r\n              <tr>\r\n                <td>{$lang_user['chars_on_realm']} " . get_realm_name($realm[0]) . "</td>\r\n                <td>{$chars_on_realm}</td>\r\n              </tr>";
                if ($chars_on_realm) {
                    $char_array = $sqlc->query("SELECT guid, name, race, class, level, gender\r\n          FROM `characters` WHERE account = {$id}");
                    while ($char = $sqlc->fetch_array($char_array)) {
                        $output .= "\r\n              <tr>\r\n                <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'---></td>\r\n                <td>\r\n                      <a href=\"char.php?id={$char['0']}&amp;realm={$realm['0']}\">{$char['1']}  - <img src='img/c_icons/{$char[2]}-{$char[5]}.gif' onmousemove='toolTip(\"" . char_get_race_name($char[2]) . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\" />\r\n                      <img src='img/c_icons/{$char[3]}.gif' onmousemove='toolTip(\"" . char_get_class_name($char[3]) . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\"/> - lvl " . char_get_level_color($char[4]) . "</a>\r\n                </td>\r\n              </tr>";
                    }
                }
            }
        } else {
            $query = $sqlc->query("SELECT count(*) FROM `characters` WHERE account = {$id}");
            $chars_on_realm = $sqlc->result($query, 0);
            $output .= "\r\n              <tr>\r\n                <td>{$lang_user['chars_on_realm']}</td>\r\n                <td>{$chars_on_realm}</td>\r\n              </tr>";
            if ($chars_on_realm) {
                $char_array = $sqlc->query("SELECT guid,name,race,class, level, gender FROM `characters` WHERE account = {$id}");
                while ($char = $sqlc->fetch_array($char_array)) {
                    $output .= "\r\n                <tr>\r\n                  <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'---></td>\r\n                  <td>\r\n                    <a href=\"char.php?id={$char['0']}\">{$char['1']}  - <img src='img/c_icons/{$char[2]}-{$char[5]}.gif' onmousemove='toolTip(\"" . char_get_race_name($char[2]) . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\" />\r\n                    <img src='img/c_icons/{$char[3]}.gif' onmousemove='toolTip(\"" . char_get_class_name($char[3]) . "\",\"item_tooltip\")' onmouseout='toolTip()' alt=\"\"/> - lvl " . char_get_level_color($char[4]) . "</a>\r\n                  </td>\r\n                </tr>";
                }
            }
        }
        $output .= "\r\n              <tr>\r\n                <td>";
        if ($user_lvl >= $action_permission['delete']) {
            makebutton($lang_user['del_acc'], "user.php?action=del_user&amp;check%5B%5D={$id}\" type=\"wrn", 130);
        }
        $output .= "\r\n                </td>\r\n                <td>";
        if ($user_lvl >= $action_permission['update']) {
            makebutton($lang_user['update_data'], "javascript:do_submit_data()", 130);
        }
        makebutton($lang_global['back'], "javascript:window.history.back()\" type=\"def", 130);
        $output .= "\r\n                </td>\r\n                </tr>\r\n              </table>\r\n            </form>\r\n          </fieldset>\r\n          <br /><br />\r\n        </center>\r\n";
    } else {
        error($lang_global['err_no_user']);
    }
}
开发者ID:scamp,项目名称:minimanager,代码行数:101,代码来源:user.php

示例5: char_rep


//.........这里部分代码省略.........
            }
            $output .= '
               </ul>
            </div>
            <div class="tab_content center">
              <div class="tab">
                <ul>
                  <li><a href="char.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "char_sheet") . '</a></li>';
            if (char_get_class_name($char["class"]) == "Hunter" && $view_pets_override) {
                $output .= '
                  <li><a href="char_pets.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "pets") . '</a></li>';
            }
            $output .= '
                  <li class="selected"><a href="char_rep.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "reputation") . '</a></li>';
            if ($view_skill_override) {
                $output .= '
                  <li><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "skills") . '</a></li>';
            }
            if ($view_pvp_override) {
                $output .= '
                  <li><a href="char_pvp.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "pvp") . '</a></li>';
            }
            if ($owner_name == $user_name || $user_lvl >= get_page_permission("insert", "char_mail.php")) {
                $output .= '
                  <li><a href="char_mail.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "mail") . '</a></li>';
            }
            $output .= '
                </ul>
              </div>
              <div class="tab_content2 center center_text">
                <span class="bold">
                  ' . htmlentities($char["name"], ENT_COMPAT, $site_encoding) . ' -
                  <img src="img/c_icons/' . $char["race"] . '-' . $char["gender"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_race_name($char["race"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" />
                  <img src="img/c_icons/' . $char["class"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_class_name($char["class"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" /> - ' . lang("char", "level_short") . char_get_level_color($char["level"]) . '
                </span>
                <br />
                <br />';
            $temp_out = array(1 => array('
                <table class="lined" id="ch_rep_rep_alliance">
                  <tr>
                    <th colspan="3" align="left">
                      <div id="divi1" onclick="expand(\'i1\', this, \'Alliance\')">[-] ' . lang("char", "rep_alliance") . '</div>
                    </th>
                  </tr>
                  <tr>
                    <td>
                      <table id="i1" class="lined" style="width: 535px; display: table;">', 0), 2 => array('
                <table class="lined" id="ch_rep_rep_horde">
                  <tr>
                    <th colspan="3" align="left">
                      <div id="divi2" onclick="expand(\'i2\', this, \'Horde\')">[-] ' . lang("char", "rep_horde") . '</div>
                    </th>
                  </tr>
                  <tr>
                    <td>
                      <table id="i2" class="lined" style="width: 535px; display: table;">', 0), 3 => array('
                <table class="lined" id="ch_rep_rep_alliance_forces">
                  <tr>
                    <th colspan="3" align="left">
                      <div id="divi3" onclick="expand(\'i3\', this, \'Alliance Forces\')">[-] ' . lang("char", "rep_alliance_forces") . '</div>
                    </th>
                  </tr>
                  <tr>
                    <td>
                      <table id="i3" class="lined" style="width: 535px; display: table;">', 0), 4 => array('
                <table class="lined" id="ch_rep_rep_horde_forces">
开发者ID:GlassFace,项目名称:CoreManager2,代码行数:67,代码来源:char_rep.php

示例6: char_rep

function char_rep(&$sqlr, &$sqlc)
{
    global $output, $lang_global, $lang_char, $realm_id, $characters_db, $mmfpm_db, $action_permission, $user_lvl, $user_name;
    require_once 'libs/fact_lib.php';
    $reputation_rank = fact_get_reputation_rank_arr();
    $reputation_rank_length = fact_get_reputation_rank_length();
    if (empty($_GET['id'])) {
        error($lang_global['empty_fields']);
    }
    // this is multi realm support, as of writing still under development
    //  this page is already implementing it
    if (empty($_GET['realm'])) {
        $realmid = $realm_id;
    } else {
        $realmid = $sqlr->quote_smart($_GET['realm']);
        if (is_numeric($realmid)) {
            $sqlc->connect($characters_db[$realmid]['addr'], $characters_db[$realmid]['user'], $characters_db[$realmid]['pass'], $characters_db[$realmid]['name']);
        } else {
            $realmid = $realm_id;
        }
    }
    $id = $sqlc->quote_smart($_GET['id']);
    if (is_numeric($id)) {
    } else {
        $id = 0;
    }
    $result = $sqlc->query('SELECT account, name, race, class, level, gender FROM characters WHERE guid = ' . $id . ' LIMIT 1');
    if ($sqlc->num_rows($result)) {
        $char = $sqlc->fetch_assoc($result);
        // we get user permissions first
        $owner_acc_id = $sqlc->result($result, 0, 'account');
        $result = $sqlr->query('SELECT gmlevel, username FROM account WHERE id = ' . $char['account'] . '');
        $owner_gmlvl = $sqlr->result($result, 0, 'gmlevel');
        $owner_name = $sqlr->result($result, 0, 'username');
        if ($user_lvl > $owner_gmlvl || $owner_name === $user_name) {
            $result = $sqlc->query('SELECT faction, standing FROM character_reputation WHERE guid = ' . $id . ' AND (flags & 1 = 1)');
            $output .= '
          <center>
           <div id="tab_content">
              <div id="tab">
                <ul>
                  <li><a href="char.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['char_sheet'] . '</a></li>
                  <li><a href="char_inv.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['inventory'] . '</a></li>
                  <li><a href="char_extra.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['extra'] . '</a></li>
                  ' . ($char['level'] < 10 ? '' : '<li><a href="char_talent.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['talents'] . '</a></li>') . '
                  <li><a href="char_achieve.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['achievements'] . '</a></li>
                  <li><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['skills'] . '</a></li>
                  <li><a href="char_quest.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['quests'] . '</a></li>';
            if (char_get_class_name($char['class']) === 'Hunter') {
                $output .= '
                  <li><a href="char_pets.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['pets'] . '</a></li>';
            }
            $output .= '
                  <li><a href="char_friends.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['friends'] . '</a></li>
				  <li><a href="char_spell.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['spells'] . '</a></li>
				  <li><a href="char_mail.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['mail'] . '</a></li>
                </ul>
                <ul>';
            // selected char tab at last
            $output .= '
                  <li id="selected"><a href="char_rep.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['reputation'] . '</a></li>';
            $output .= '
              </ul>
            </div>
            <div id="tab_content2">
              <font class="bold">
                ' . htmlentities($char['name']) . ' -
                <img src="img/c_icons/' . $char['race'] . '-' . $char['gender'] . '.gif"
                  onmousemove="toolTip(\'' . char_get_race_name($char['race']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
                <img src="img/c_icons/' . $char['class'] . '.gif"
                  onmousemove="toolTip(\'' . char_get_class_name($char['class']) . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" /> - lvl ' . char_get_level_color($char['level']) . '
              </font>
              <br /><br />';
            $temp_out = array(1 => array('
                <table class="lined" style="width: 550px;">
                  <tr>
                    <th colspan="3" align="left">
                      <div id="divi1" onclick="expand(\'i1\', this, \'Alliance\')">[-] Alliance</div>
                    </th>
                  </tr>
                  <tr>
                    <td>
                      <table id="i1" class="lined" style="width: 535px; display: table;">', 0), 2 => array('
                <table class="lined" style="width: 550px;">
                  <tr>
                    <th colspan="3" align="left">
                      <div id="divi2" onclick="expand(\'i2\', this, \'Horde\')">[-] Horde</div>
                    </th>
                  </tr>
                  <tr>
                    <td>
                      <table id="i2" class="lined" style="width: 535px; display: table;">', 0), 3 => array('
                <table class="lined" style="width: 550px;">
                  <tr>
                    <th colspan="3" align="left">
                      <div id="divi3" onclick="expand(\'i3\', this, \'Alliance Forces\')">[-] Alliance Forces</div>
                    </th>
                  </tr>
                  <tr>
                    <td>
//.........这里部分代码省略.........
开发者ID:scamp,项目名称:minimanager,代码行数:101,代码来源:char_rep.php

示例7: char_mail

function char_mail(&$sqlr, &$sqlc)
{
    global $output, $lang_global, $lang_char, $lang_mail, $realm_id, $realm_db, $mmfpm_db, $characters_db, $action_permission, $user_lvl, $user_name, $item_datasite, $itemperpage;
    if (empty($_GET['id'])) {
        error($lang_global['empty_fields']);
    }
    // this is multi realm support, as of writing still under development
    //  this page is already implementing it
    if (empty($_GET['realm'])) {
        $realmid = $realm_id;
    } else {
        $realmid = $sqlr->quote_smart($_GET['realm']);
        if (is_numeric($realmid)) {
            $sqlc->connect($characters_db[$realmid]['addr'], $characters_db[$realmid]['user'], $characters_db[$realmid]['pass'], $characters_db[$realmid]['name']);
        } else {
            $realmid = $realm_id;
        }
    }
    $id = $sqlc->quote_smart($_GET['id']);
    if (is_numeric($id)) {
    } else {
        $id = 0;
    }
    //==========================$_GET and SECURE=================================
    $start = isset($_GET['start']) ? $sqlc->quote_smart($_GET['start']) : 0;
    if (is_numeric($start)) {
    } else {
        $start = 0;
    }
    $order_by = isset($_GET['order_by']) ? $sqlc->quote_smart($_GET['order_by']) : 'id';
    if (preg_match('/^[_[:lower:]]{1,12}$/', $order_by)) {
    } else {
        $order_by = 'id';
    }
    $dir = isset($_GET['dir']) ? $sqlc->quote_smart($_GET['dir']) : 1;
    if (preg_match('/^[01]{1}$/', $dir)) {
    } else {
        $dir = 1;
    }
    $order_dir = $dir ? 'ASC' : 'DESC';
    $dir = $dir ? 0 : 1;
    //==========================$_GET and SECURE end=============================
    // getting character data from database
    $result = $sqlc->query('SELECT account, name, race, class, level, gender
    FROM characters WHERE guid = ' . $id . ' LIMIT 1');
    if ($sqlc->num_rows($result)) {
        $char = $sqlc->fetch_assoc($result);
        // we get user permissions first
        $owner_acc_id = $sqlc->result($result, 0, 'account');
        $result = $sqlr->query('SELECT gmlevel, username FROM account WHERE id = ' . $char['account'] . '');
        $owner_gmlvl = $sqlr->result($result, 0, 'gmlevel');
        $owner_name = $sqlr->result($result, 0, 'username');
        if ($user_lvl > $owner_gmlvl || $owner_name === $user_name) {
            //------------------------Character Tabs---------------------------------
            // we start with a lead of 10 spaces,
            //  because last line of header is an opening tag with 8 spaces
            //  keep html indent in sync, so debuging from browser source would be easy to read
            $output .= '
          <center>
           <div id="tab_content">
              <div id="tab">
                <ul>
                  <li><a href="char.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['char_sheet'] . '</a></li>
                  <li><a href="char_inv.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['inventory'] . '</a></li>
                  <li><a href="char_extra.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['extra'] . '</a></li>
                  ' . ($char['level'] < 10 ? '' : '<li><a href="char_talent.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['talents'] . '</a></li>') . '
                  <li><a href="char_achieve.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['achievements'] . '</a></li>
                  <li><a href="char_rep.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['reputation'] . '</a></li>
                  <li><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['skills'] . '</a></li>
				  <li><a href="char_quest.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['quests'] . '</a></li>';
            if (char_get_class_name($char['class']) === 'Hunter') {
                $output .= '
                  <li><a href="char_pets.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['pets'] . '</a></li>';
            }
            $output .= '
                  <li><a href="char_friends.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['friends'] . '</a></li>
				  <li><a href="char_spell.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['spells'] . '</a></li>
                </ul>
                <ul>';
            // selected char tab at last
            $output .= '
                  <li id="selected"><a href="char_mail.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['mail'] . '</a></li>';
            $output .= '
              </ul>
            </div>
            <div id="tab_content2">
              <font class="bold">
                ' . htmlentities($char['name']) . ' -
                <img src="img/c_icons/' . $char['race'] . '-' . $char['gender'] . '.gif"
                  onmousemove="toolTip(\'' . char_get_race_name($char['race']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
                <img src="img/c_icons/' . $char['class'] . '.gif"
                  onmousemove="toolTip(\'' . char_get_class_name($char['class']) . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" /> - lvl ' . char_get_level_color($char['level']) . '
              </font>
              <br /><br />
              <table class="lined" style="width: 100%">';
            //---------------Page Specific Starts Ends here----------------------------
            $query = $sqlc->query('SELECT a.id as id, a.messageType as messagetype, a.sender as sender,
        a.subject as subject, a.itemTextId as itemtextid, a.has_items as hasitems, a.money as money, a.cod as cod, a.checked as checked,
        b.item_template as itemtemplate
        FROM mail a INNER JOIN mail_items b ON a.id = b.mail_id where a.receiver = ' . $id . ' LIMIT ' . $start . ', ' . $itemperpage . '');
//.........这里部分代码省略.........
开发者ID:scamp,项目名称:minimanager,代码行数:101,代码来源:char_mail.php

示例8: instances

function instances()
{
    global $output, $lang_instances, $realm_id, $world_db, $mmfpm_db, $itemperpage;
    $sqlw = new SQL();
    $sqlw->connect($world_db[$realm_id]['addr'], $world_db[$realm_id]['user'], $world_db[$realm_id]['pass'], $world_db[$realm_id]['name']);
    //-------------------SQL Injection Prevention--------------------------------
    // this page has multipage support and field ordering, so we need these
    $start = isset($_GET['start']) ? $sqlw->quote_smart($_GET['start']) : 0;
    if (is_numeric($start)) {
    } else {
        $start = 0;
    }
    $order_by = isset($_GET['order_by']) ? $sqlw->quote_smart($_GET['order_by']) : 'levelMin';
    if (preg_match('/^[_[:lower:]]{1,11}$/', $order_by)) {
    } else {
        $order_by = 'levelMin';
    }
    $dir = isset($_GET['dir']) ? $sqlw->quote_smart($_GET['dir']) : 1;
    if (preg_match('/^[01]{1}$/', $dir)) {
    } else {
        $dir = 1;
    }
    $order_dir = $dir ? 'ASC' : 'DESC';
    $dir = $dir ? 0 : 1;
    //-------------------SQL Injection Prevention--------------------------------
    // for multipage support
    $all_record = $sqlw->result($sqlw->query('SELECT count(*) FROM instance_template'), 0);
    // main data that we need for this page, instances
    $result = $sqlw->query('
		SELECT map, levelMin, levelMax
		FROM instance_template
		ORDER BY ' . $order_by . ' ' . $order_dir . ' LIMIT ' . $start . ', ' . $itemperpage . ';');
    //---------------Page Specific Data Starts Here--------------------------
    $output .= '
<center>
<table class="top_hidden">
	<tr>
		<td width="25%" align="right">';
    // multi page links
    $output .= $lang_instances['total'] . ' : ' . $all_record . '<br /><br />' . generate_pagination('instances.php?order_by=' . $order_by . '&amp;dir=' . ($dir ? 0 : 1), $all_record, $itemperpage, $start);
    // column headers, with links for sorting
    $output .= '
		</td>
	</tr>
</table>
<table class="lined">
	<tr>
		<th width="20%"><a href="instances.php?order_by=map&amp;start=' . $start . '&amp;dir=' . $dir . '"' . ($order_by === 'map' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_instances['map'] . '</a></th>
		<th width="5%"><a href="instances.php?order_by=levelMin&amp;start=' . $start . '&amp;dir=' . $dir . '"' . ($order_by === 'levelMin' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_instances['level_min'] . '</a></th>
		<th width="5%"><a href="instances.php?order_by=levelMax&amp;start=' . $start . '&amp;dir=' . $dir . '"' . ($order_by === 'levelMax' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_instances['level_max'] . '</a></th>
		<th width="20%">' . $lang_instances['area'] . '</th>
		<th width="10%">' . $lang_instances['type'] . '</th>
		<th width="5%">' . $lang_instances['expansion'] . '</th>
		<th width="5%">' . $lang_instances['ppl'] . '</th>
	</tr>';
    $sqlm = new SQL();
    $sqlm->connect($mmfpm_db['addr'], $mmfpm_db['user'], $mmfpm_db['pass'], $mmfpm_db['name']);
    while ($instances = $sqlw->fetch_assoc($result)) {
        $output .= '
	<tr valign="top">
		<td>' . get_map_name($instances['map'], $sqlm) . '</td>
		<td>' . char_get_level_color($instances['levelMin']) . '</td>
		<td>' . char_get_level_color($instances['levelMax']) . '</td>
		<td>' . get_map_zone($instances['map'], $sqlm) . '</td>
		<td>' . get_map_type($instances['map'], $sqlm) . '</td>
		<td>' . get_map_exp($instances['map'], $sqlm) . '</td>
		<td>' . get_map_ppl($instances['map'], $sqlm) . '</td>
	</tr>';
    }
    unset($reset);
    unset($hours);
    unset($days);
    unset($instances);
    unset($result);
    $output .= '
</table>
<table class="top_hidden">
	<tr>
		<td width="25%" align="right">';
    // multi page links
    $output .= $lang_instances['total'] . ' : ' . $all_record . '<br /><br />' . generate_pagination('instances.php?order_by=' . $order_by . '&amp;dir=' . ($dir ? 0 : 1), $all_record, $itemperpage, $start);
    unset($start);
    $output .= '
		</td>
	</tr>
</table>
</center>';
}
开发者ID:BACKUPLIB,项目名称:Infinity_MaNGOS,代码行数:88,代码来源:instances.php

示例9: char_inv


//.........这里部分代码省略.........
              <ul>
                <li><a href="char.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "char_sheet") . '</a></li>';
            $output .= '
                <li class="selected"><a href="char_inv.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "inventory") . '</a></li>';
            if ($view_talent_override) {
                $output .= '
                ' . ($char["level"] < 10 ? '' : '<li><a href="char_talent.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "talents") . '</a></li>') . '';
            }
            if ($view_achieve_override) {
                $output .= '
                <li><a href="char_achieve.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "achievements") . '</a></li>';
            }
            if ($view_quest_override) {
                $output .= '
                <li><a href="char_quest.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "quests") . '</a></li>';
            }
            if ($view_friends_override) {
                $output .= '
                <li><a href="char_friends.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "friends") . '</a></li>';
            }
            if ($view_view_override) {
                $output .= '
                <li><a href="char_view.php?id=' . $cid . '&amp;realm=' . $realmid . '">' . lang("char", "view") . '</a></li>';
            }
            $output .= '
              </ul>
            </div>
            <div class="tab_content center" id="ch_inv_bags_wrap">
              <span class="bold">
                ' . htmlentities($char["name"], ENT_COMPAT, $site_encoding) . ' -
                <img src="img/c_icons/' . $char["race"] . '-' . $char["gender"] . '.gif"
                  onmousemove="oldtoolTip(\'' . char_get_race_name($char["race"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" />
                <img src="img/c_icons/' . $char["class"] . '.gif"
                  onmousemove="oldtoolTip(\'' . char_get_class_name($char["class"]) . '\',\'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" /> - ' . lang("char", "level_short") . char_get_level_color($char["level"]) . '
              </span>
              <br />
              <br />
              <table class="lined" id="ch_inv_bags">
                <tr>';
            //---------------Page Specific Data Starts Here--------------------------
            // equipped bags
            for ($i = 4; $i > 0; --$i) {
                $output .= '
                  <th>';
                if ($equiped_bag_id[$i]) {
                    $output .= '
                    <a href="' . $base_datasite . $item_datasite . $equiped_bag_id[$i][0] . '" rel="external">
                      <img class="bag_icon" src="' . get_item_icon($equiped_bag_id[$i][0]) . '" alt="" />
                    </a>
                    ' . lang("item", "bag") . ' ' . $i . '<br />
                    <span class="small">' . $equiped_bag_id[$i][1] . ' ' . lang("item", "slots") . '</span>';
                }
                $output .= '
                  </th>';
            }
            $output .= '
                </tr>
                <tr>';
            // equipped bag slots
            for ($t = 4; $t > 0; --$t) {
                // this_is_junk: style left hardcoded because it's calculated.
                $output .= '
                  <td align="center">
                    <div class="bag" style="width: ' . 4 * 43 . 'px; height: ' . ceil($equiped_bag_id[$t][1] / 4) * 41 . 'px;">';
                $dsp = $equiped_bag_id[$t][1] % 4;
                if ($dsp) {
开发者ID:xhaher,项目名称:CoreManager,代码行数:67,代码来源:char_inv.php

示例10: view_raffle


//.........这里部分代码省略.........
                        }
                        $char_list[] = $realm_char_list;
                    }
                    for ($i = 0; $i < count($char_list); $i++) {
                        $realm_chars = $char_list[$i];
                        $cur_realm = $realm_list[$i];
                        $realm_name_query = "SELECT * FROM config_servers WHERE `Index`='" . $cur_realm . "'";
                        $realm_name_result = $sql["mgr"]->query($realm_name_query);
                        $realm_name_result = $sql["mgr"]->fetch_assoc($realm_name_result);
                        $cur_realm_name = $realm_name_result["Name"];
                        $sqlt = new SQL();
                        $sqlt->connect($characters_db[$cur_realm]["addr"], $characters_db[$cur_realm]["user"], $characters_db[$cur_realm]["pass"], $characters_db[$cur_realm]["name"], $characters_db[$cur_realm]["encoding"]);
                        if (count($realm_list) > 1) {
                            $output .= '
                    <div class="coupon_part_chars">
                      <span>' . $cur_realm_name . '</span>
                    </div>';
                        }
                        $output .= '
                    <div class="coupon_part_chars">
                      <div class="fake_table">';
                        $first = true;
                        // we want the first character to be selected
                        foreach ($realm_chars as $row) {
                            if ($core == 1) {
                                $char_query = "SELECT *, gold AS money FROM characters WHERE guid='" . $row . "'";
                            } else {
                                $char_query = "SELECT * FROM characters WHERE guid='" . $row . "'";
                            }
                            $char_result = $sqlt->query($char_query);
                            $char = $sqlt->fetch_assoc($char_result);
                            // extract gold/silver/copper from single gold number
                            $char["money"] = str_pad($char["money"], 4, "0", STR_PAD_LEFT);
                            $char_g = substr($char["money"], 0, -4);
                            if ($char_g == "") {
                                $char_g = 0;
                            }
                            $char_s = substr($char["money"], -4, 2);
                            if ($char_s == "" || $char_s == "00") {
                                $char_s = 0;
                            }
                            $char_c = substr($char["money"], -2);
                            if ($char_c == "" || $char_c == "00") {
                                $char_c = 0;
                            }
                            $output .= '
                        <div class="fake_table_cell">
                          <input type="radio" name="money_character" value="' . ($i + 1) . "-" . $row . '-' . $char["name"] . '"' . (isset($first) ? ' checked="checked"' : '') . ($char["online"] || $char["money"] < $raffle["cost_money"] ? ' disabled="disabled"' : '') . ' />
                          <a href="char.php?id=' . $row . '&amp;realm=' . $cur_realm . '">' . $char["name"] . '</a> - <img src="img/c_icons/' . $char["race"] . '-' . $char["gender"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_race_name($char["race"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" />
                          <img src="img/c_icons/' . $char["class"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_class_name($char["class"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt=""/> - ' . lang("char", "level_short") . char_get_level_color($char["level"]) . '
                        </div>
                        <div class="fake_table_cell">
                          <span>' . $char_g . '</span>
                          <img src="img/gold.gif" alt="gold" style="position: relative; bottom: -6px;" />
                          <span>' . $char_s . '</span>
                          <img src="img/silver.gif" alt="silver" style="position: relative; bottom: -6px;" />
                          <span>' . $char_c . '</span>
                          <img src="img/copper.gif" alt="copper" style="position: relative; bottom: -6px;" />
                        </div>';
                            unset($first);
                        }
                    }
                }
                $output .= '
                      </div>
                    </div>
                  </td>
                </tr>';
            }
            if ($raffle["tickets_per_user"] > 1) {
                $output .= '
                <tr>
                  <td>
                    <div class="coupon_parts">' . lang("points", "tickets_purchased") . ':&nbsp;<b>' . $my_usage_count . '</b></div>
                  </td>
                </tr>';
            }
            $output .= '
                <tr>
                  <td align="right">
                    <a href="javascript:do_submit(\'form1\',0)">
                      <img src="img/aff_tick.png" width="16" height="16" alt="" />
                      <span>&nbsp;' . lang("points", "confirm_purchase") . '</span>
                    </a>
                  </td>
                </tr>
              </table>
            </form>';
        }
    } else {
        $output .= '
          <div class="tab_content center">';
        $output .= '
            <span>' . lang("points", "purchased") . '</span>';
    }
    $output .= '
          </div>
          <br />
          <!-- end of point_system.php -->';
}
开发者ID:GlassFace,项目名称:CoreManager2,代码行数:101,代码来源:point_system.php

示例11: edit_user


//.........这里部分代码省略.........
                $sql["char"]->connect($characters_db[$realm["Index"]]["addr"], $characters_db[$realm["Index"]]["user"], $characters_db[$realm["Index"]]["pass"], $characters_db[$realm["Index"]]["name"], $characters_db[$realm["Index"]]["encoding"]);
                if ($core == 1) {
                    $result = $sql["char"]->query("SELECT guid, name, race, class, level, gender, timestamp,\n            IFNULL((SELECT SUM(points) FROM character_achievement LEFT JOIN `" . $dbc_db["name"] . "`.achievement ON `" . $dbc_db["name"] . "`.achievement.id=character_achievement.achievement WHERE character_achievement.guid=characters.guid), 0) AS ach_points\n            FROM characters WHERE acct='" . $user_id . "'");
                } else {
                    $result = $sql["char"]->query("SELECT guid, name, race, class, level, gender, logout_time AS timestamp,\n            IFNULL((SELECT SUM(points) FROM character_achievement LEFT JOIN `" . $dbc_db["name"] . "`.achievement ON `" . $dbc_db["name"] . "`.achievement.id=character_achievement.achievement WHERE character_achievement.guid=characters.guid), 0) AS ach_points\n            FROM characters WHERE account='" . $user_id . "'");
                }
                // calculate timezone offset
                $time_offset = $timezone_offset * 3600;
                $output .= '
                    <tr>
                      <td colspan="3">&nbsp;</td>
                    </tr>
                    <tr>
                      <td colspan="3">' . lang("index", "realm") . ': ' . $realm["Name"] . '</td>
                    </tr>
                    <tr>
                      <td>' . lang("edit", "characters") . ':</td>
                      <td>' . $sql["char"]->num_rows($result) . '</td>
                    </tr>';
                while ($char = $sql["char"]->fetch_assoc($result)) {
                    if ($char["timestamp"] != 0) {
                        $lastseen = date("F j, Y @ Hi", $char["timestamp"] + $time_offset);
                    } else {
                        $lastseen = '-';
                    }
                    // add this character's achievement points to our total
                    $total_achieve_points += $char["ach_points"];
                    $output .= '
                    <tr>
                      <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\'---></td>
                      <td>
                        <a href="char.php?id=' . $char["guid"] . '&amp;realm=' . $realm["Index"] . '">' . $char["name"] . '</a> -
                        <img src="img/c_icons/' . $char["race"] . '-' . $char["gender"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_race_name($char["race"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" />
                        <img src="img/c_icons/' . $char["class"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_class_name($char["class"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" /> - ' . lang("char", "level_short") . char_get_level_color($char["level"]) . '
                      </td>
                      <td>' . $lastseen . '</td>
                    </tr>';
                }
            }
            unset($realm);
        } else {
            if ($core == 1) {
                $result = $sql["char"]->query("SELECT guid, name, race, class, level, gender, timestamp,\n          IFNULL((SELECT SUM(points) FROM character_achievement LEFT JOIN `" . $dbc_db["name"] . "`.achievement ON `" . $dbc_db["name"] . "`.achievement.id=character_achievement.achievement WHERE character_achievement.guid=characters.guid), 0) AS ach_points\n          FROM characters WHERE acct='" . $user_id . "'");
            } else {
                $result = $sql["char"]->query("SELECT guid, name, race, class, level, gender, logout_time AS timestamp,\n          IFNULL((SELECT SUM(points) FROM character_achievement LEFT JOIN `" . $dbc_db["name"] . "`.achievement ON `" . $dbc_db["name"] . "`.achievement.id=character_achievement.achievement WHERE character_achievement.guid=characters.guid), 0) AS ach_points\n          FROM characters WHERE account='" . $user_id . "'");
            }
            // calculate timezone offset
            $time_offset = $timezone_offset * 3600;
            $output .= '
                  <!-- tr>
                    <td>' . lang("edit", "characters") . ':</td>
                    <td>' . $sql["char"]->num_rows($result) . '</td>
                  </tr -->';
            while ($char = $sql["char"]->fetch_assoc($result)) {
                if ($char["timestamp"] != 0) {
                    $lastseen = date("F j, Y @ Hi", $char["timestamp"] + $time_offset);
                } else {
                    $lastseen = '-';
                }
                // add this character's achievement points to our total
                $total_achieve_points += $char["ach_points"];
                $output .= '
                  <tr>
                    <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\'---></td>
                    <td>
                      <a href="char.php?id=' . $char["guid"] . '">' . $char["name"] . '</a> -
开发者ID:Refuge89,项目名称:World-of-Warcraft-Trinity-Core-MaNGOS,代码行数:67,代码来源:edit.php

示例12: char_skill


//.........这里部分代码省略.........
            }
            $output .= '
              </ul>
            </div>
            <div class="tab_content center">
              <div class="tab">
                <ul>
                  <li><a href="char.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "char_sheet") . '</a></li>';
            if (char_get_class_name($char["class"]) == "Hunter" && $view_pets_override) {
                $output .= '
                  <li><a href="char_pets.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "pets") . '</a></li>';
            }
            if ($view_rep_override) {
                $output .= '
                  <li><a href="char_rep.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "reputation") . '</a></li>';
            }
            $output .= '
                  <li class="selected"><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "skills") . '</a></li>';
            if ($view_pvp_override) {
                $output .= '
                  <li><a href="char_pvp.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "pvp") . '</a></li>';
            }
            if ($owner_name == $user_name || $user_lvl >= get_page_permission("insert", "char_mail.php")) {
                $output .= '
                  <li><a href="char_mail.php?id=' . $id . '&amp;realm=' . $realmid . '">' . lang("char", "mail") . '</a></li>';
            }
            $output .= '
                </ul>
              </div>
              <div class="tab_content2 center center_text">
                <span class="bold">
                  ' . htmlentities($char["name"], ENT_COMPAT, $site_encoding) . ' -
                  <img src="img/c_icons/' . $char["race"] . '-' . $char["gender"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_race_name($char["race"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" />
                  <img src="img/c_icons/' . $char["class"] . '.gif" onmousemove="oldtoolTip(\'' . char_get_class_name($char["class"]) . '\', \'old_item_tooltip\')" onmouseout="oldtoolTip()" alt="" /> - ' . lang("char", "level_short") . char_get_level_color($char["level"]) . '
                </span>
                <br />
                <br />
                <table class="lined" id="ch_ski_main">
                  <tr>
                    <th class="title" colspan="' . ($user_lvl ? '3' : '2') . '" align="left">' . lang("char", "skills") . '</th>
                  </tr>
                  <tr>
                    ' . ($user_lvl ? '<th><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '&amp;order_by=0&amp;dir=' . $dir . '"' . ($order_by == 0 ? ' class="' . $order_dir . '"' : '') . '>' . lang("char", "skill_id") . '</a></th>' : '') . '
                    <th align="right"><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '&amp;order_by=1&amp;dir=' . $dir . '"' . ($order_by == 1 ? ' class="' . $order_dir . '"' : '') . '>' . lang("char", "skill_name") . '</a></th>
                    <th><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '&amp;order_by=2&amp;dir=' . $dir . '"' . ($order_by == 2 ? ' class="' . $order_dir . '"' : '') . '>' . lang("char", "skill_value") . '</a></th>
                  </tr>';
            $skill_array = array();
            $class_array = array();
            $prof_1_array = array();
            $prof_2_array = array();
            $weapon_array = array();
            $armor_array = array();
            $language_array = array();
            $skill_rank_array = array(75 => lang("char", "apprentice"), 150 => lang("char", "journeyman"), 225 => lang("char", "expert"), 300 => lang("char", "artisan"), 375 => lang("char", "master"), 450 => lang("char", "inherent"), 385 => lang("char", "wise"));
            for ($i = PLAYER_SKILL_INFO_1_1; $i <= PLAYER_SKILL_INFO_1_1 + 384; $i += 3) {
                if ($char_data[$i] && skill_get_name($char_data[$i] & 0xffff)) {
                    $temp = unpack("S", pack("L", $char_data[$i + 1]));
                    $skill = $char_data[$i] & 0xffff;
                    if (skill_get_type($skill) == 6) {
                        array_push($weapon_array, array($user_lvl ? $skill : '', skill_get_name($skill), $temp[1]));
                    } elseif (skill_get_type($skill) == 7) {
                        array_push($class_array, array($user_lvl ? $skill : '', skill_get_name($skill), $temp[1]));
                    } elseif (skill_get_type($skill) == 8) {
                        array_push($armor_array, array($user_lvl ? $skill : '', skill_get_name($skill), $temp[1]));
                    } elseif (skill_get_type($skill) == 9) {
                        array_push($prof_2_array, array($user_lvl ? $skill : '', skill_get_name($skill), $temp[1]));
开发者ID:xhaher,项目名称:CoreManager,代码行数:67,代码来源:char_skill.php

示例13: index


//.........这里部分代码省略.........
        $output .= '
		</td>
	</tr>
	<tr>
		<th width="15%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=name&amp;dir=' . $dir . '"' . ($order_by === 'name' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['name'] . '</a></th>
		<th width="1%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=race&amp;dir=' . $dir . '"' . ($order_by === 'race' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['race'] . '</a></th>
		<th width="1%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=class&amp;dir=' . $dir . '"' . ($order_by === 'class' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['class'] . '</a></th>
		<th width="5%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=level&amp;dir=' . $dir . '"' . ($order_by === 'level' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['level'] . '</a></th>
		<th width="1%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=totalHonorPoints&amp;dir=' . $dir . '"' . ($order_by === 'totalHonorPoints' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['rank'] . '</a></th>
		<th width="15%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=guildid&amp;dir=' . $dir . '"' . ($order_by === 'gname' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['guild'] . '</a></th>
		<th width="20%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=map&amp;dir=' . $dir . '"' . ($order_by === 'map ' . $order_dir . ', zone' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['map'] . '</a></th>
		<th width="25%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=zone&amp;dir=' . $dir . '"' . ($order_by === 'zone ' . $order_dir . ', map' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['zone'] . '</a></th>';
        if ($showcountryflag) {
            require_once 'libs/misc_lib.php';
            $output .= '
		<th width="1%">' . $lang_global['country'] . '</th>';
        }
        $output .= '
	</tr>';
        $sqlm = new SQL();
        $sqlm->connect($mmfpm_db['addr'], $mmfpm_db['user'], $mmfpm_db['pass'], $mmfpm_db['name']);
        while ($char = $sqlc->fetch_assoc($result)) {
            if ($order_by == 'ip') {
                $temp = $sqlc->fetch_assoc($sqlc->query('
					SELECT characters.guid, characters.name, characters.race, characters.class, characters.zone, characters.map, characters.level, characters.account, characters.gender, characters.totalHonorPoints,
						COALESCE(guild_member.guildid,0) AS guildid 
					FROM characters LEFT JOIN guild_member ON guild_member.guid = characters.guid 
					WHERE characters.online= 1 ' . ($gm_online == '0' ? 'AND characters.extra_flags &1 = 0 ' : '') . $order_side . ' and account = ' . $char['id']));
                if (isset($temp['guid'])) {
                    $char = $temp;
                } else {
                    continue;
                }
            }
            $gm = $sqlr->result($sqlr->query('
			SELECT gmlevel 
			FROM account 
			WHERE id=' . $char['account'] . ''), 0);
            $guild_name = $sqlc->result($sqlc->query('
			SELECT name 
			FROM guild 
			WHERE guildid=' . $char['guildid'] . ''));
            $output .= '
	<tr>
		<td>';
            if ($user_lvl >= $gm) {
                $output .= '
			<a href="char.php?id=' . $char['guid'] . '">
				<span onmousemove="toolTip(\'' . id_get_gm_level($gm) . '\', \'item_tooltip\')" onmouseout="toolTip()">' . htmlentities($char['name']) . '</span>
			</a>';
            } else {
                $output .= '
			' . htmlentities($char['name']) . '</span>';
            }
            $output .= '
		</td>
		<td>
			<img src="img/c_icons/' . $char['race'] . '-' . $char['gender'] . '.gif" onmousemove="toolTip(\'' . char_get_race_name($char['race']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
		</td>
		<td>
			<img src="img/c_icons/' . $char['class'] . '.gif" onmousemove="toolTip(\'' . char_get_class_name($char['class']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
		</td>
		<td>' . char_get_level_color($char['level']) . '</td>
		<td>
			<span onmouseover="toolTip(\'' . char_get_pvp_rank_name($char['totalHonorPoints'], char_get_side_id($char['race'])) . '\', \'item_tooltip\')" onmouseout="toolTip()" style="color: white;"><img src="img/ranks/rank' . char_get_pvp_rank_id($char['totalHonorPoints'], char_get_side_id($char['race'])) . '.gif" alt="" /></span>
		</td>
		<td>
			<a href="guild.php?action=view_guild&amp;error=3&amp;id=' . $char['guildid'] . '">' . htmlentities($guild_name) . '</a>
		</td>
		<td>
			<span onmousemove="toolTip(\'MapID:' . $char['map'] . '\', \'item_tooltip\')" onmouseout="toolTip()">' . get_map_name($char['map'], $sqlm) . '</span>
		</td>
		<td>
			<span onmousemove="toolTip(\'ZoneID:' . $char['zone'] . '\', \'item_tooltip\')" onmouseout="toolTip()">' . get_zone_name($char['zone'], $sqlm) . '</span>
		</td>';
            if ($showcountryflag) {
                $country = misc_get_country_by_account($char['account'], $sqlr, $sqlm);
                $output .= '
		<td>
			' . ($country['code'] ? '<img src="img/flags/' . $country['code'] . '.png" onmousemove="toolTip(\'' . $country['country'] . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" />' : '-') . '
		</td>';
            }
            $output .= '
	</tr>';
        }
        $output .= '
	<tr>';
        $output .= '
		<td colspan="' . (10 - $showcountryflag) . '" align="right" class="hidden" width="25%">';
        $output .= generate_pagination('index.php?start_m=' . $start_m . '&amp;order_by=' . $order_by . '&amp;dir=' . ($dir ? 0 : 1), $total_online, $itemperpage, $start);
        unset($total_online);
        $output .= '
		</td>
	</tr>
	</table>
</fieldset>
<br />
</center>';
    }
}
开发者ID:BACKUPLIB,项目名称:minimanager-1,代码行数:101,代码来源:index.php

示例14: front


//.........这里部分代码省略.........
        } else {
            $result = $sqlc->query('SELECT characters.guid,  characters.name,  characters.race,  characters.class,  characters.zone,  characters.map,  characters.level,  characters.account,  characters.gender,  characters.totalHonorPoints, COALESCE(guild_member.guildid,0) AS guildid FROM characters LEFT JOIN guild_member ON guild_member.guid = characters.guid WHERE characters.online = 1 ' . ($gm_online == '0' ? 'AND characters.extra_flags &1 = 0 ' : '') . $order_side . ' ORDER BY ' . $order_by . ' ' . $order_dir . ' LIMIT ' . $start . ', ' . $itemperpage);
        }
        $total_online = $sqlc->result($sqlc->query('SELECT count(*) FROM characters WHERE online= 1' . ($gm_online_count == '0' ? ' AND extra_flags &1 = 0' : '')), 0);
        $replace = '
              <tr>
                <td align="right" class="hidden">' . generate_pagination('index.php?start=' . $start . '&amp;order_by=' . $order_by . '&amp;dir=' . ($dir ? 0 : 1) . '', $all_record_m, 3, $start_m, 'start_m') . '</td>
              </tr>';
        unset($all_record_m);
        $output = str_replace('%%REPLACE_TAG%%', $replace, $output);
        unset($replace);
        $output .= '
                    <font class="bold">' . $lang_index['tot_users_online'] . ': ' . $total_online . '</font>
                    <table class="lined">
                        <tr>
                            <td colspan="' . (10 - $showcountryflag) . '" align="right" class="hidden" width="25%">';
        $output .= generate_pagination('index.php?start_m=' . $start_m . '&amp;order_by=' . $order_by . '&amp;dir=' . ($dir ? 0 : 1), $total_online, $itemperpage, $start);
        $output .= '
                            </td>
                        </tr>
                        <tr>
                            <th width="15%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=name&amp;dir=' . $dir . '"' . ($order_by === 'name' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['name'] . '</a></th>
                            <th width="1%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=race&amp;dir=' . $dir . '"' . ($order_by === 'race' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['race'] . '</a></th>
                            <th width="1%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=class&amp;dir=' . $dir . '"' . ($order_by === 'class' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['class'] . '</a></th>
                            <th width="5%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=level&amp;dir=' . $dir . '"' . ($order_by === 'level' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['level'] . '</a></th>
                            <th width="1%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=totalHonorPoints&amp;dir=' . $dir . '"' . ($order_by === 'totalHonorPoints' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['rank'] . '</a></th>
                            <th width="15%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=guildid&amp;dir=' . $dir . '"' . ($order_by === 'guildid' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['guild'] . '</a></th>
                            <th width="20%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=map&amp;dir=' . $dir . '"' . ($order_by === 'map ' . $order_dir . ', zone' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['map'] . '</a></th>
                            <th width="25%"><a href="index.php?start=' . $start . '&amp;start_m=' . $start_m . '&amp;order_by=zone&amp;dir=' . $dir . '"' . ($order_by === 'zone ' . $order_dir . ', map' ? ' class="' . $order_dir . '"' : '') . '>' . $lang_index['zone'] . '</a></th>';
        if ($showcountryflag) {
            require_once 'libs/misc_lib.php';
            $output .= '
                            <th width="1%">' . $lang_global['country'] . '</th>';
        }
        $output .= '
                        </tr>';
        $sqlm = new SQL();
        $sqlm->connect($mmfpm_db['addr'], $mmfpm_db['user'], $mmfpm_db['pass'], $mmfpm_db['name']);
        while ($char = $sqlc->fetch_assoc($result)) {
            if ($order_by == 'ip') {
                $temp = $sqlc->fetch_assoc($sqlc->query('SELECT characters.guid,  characters.name,  characters.race,  characters.class,  characters.zone,  characters.map,  characters.level,  characters.account,  characters.gender,  characters.totalHonorPoints, COALESCE(guild_member.guildid,0) AS guildid FROM characters LEFT JOIN guild_member ON guild_member.guid = characters.guid WHERE characters.online= 1 ' . ($gm_online == '0' ? 'AND characters.extra_flags &1 = 0 ' : '') . $order_side . ' and account = ' . $char['id']));
                if (isset($temp['guid'])) {
                    $char = $temp;
                } else {
                    continue;
                }
            }
            $gm = $sqlr->result($sqlr->query('SELECT gmlevel FROM account_access WHERE id=' . $char['account'] . ''), 0);
            $guild_name = $sqlc->result($sqlc->query('SELECT name FROM guild WHERE guildid=' . $char['guildid'] . ''));
            $output .= '
                        <tr>
                            <td>';
            if ($user_lvl >= $gm) {
                $output .= '
                                <a href="char.php?id=' . $char['guid'] . '">
                                    <span onmousemove="toolTip(\'' . id_get_gm_level($gm) . '\', \'item_tooltip\')" onmouseout="toolTip()">' . htmlentities($char['name']) . '</span>
                                </a>';
            } else {
                $output .= '
                                <span onmousemove="toolTip(\'' . id_get_gm_level($gm) . '\', \'item_tooltip\')" onmouseout="toolTip()">' . htmlentities($char['name']) . '</span>';
            }
            $output .= '
                            </td>
                            <td>
                                <img src="img/c_icons/' . $char['race'] . '-' . $char['gender'] . '.gif" onmousemove="toolTip(\'' . char_get_race_name($char['race']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
                            </td>
                            <td>
                                <img src="img/c_icons/' . $char['class'] . '.gif" onmousemove="toolTip(\'' . char_get_class_name($char['class']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
                            </td>
                            <td>' . char_get_level_color($char['level']) . '</td>
                            <td>
                                <span onmouseover="toolTip(\'' . char_get_pvp_rank_name($char['totalHonorPoints'], char_get_side_id($char['race'])) . '\', \'item_tooltip\')" onmouseout="toolTip()" style="color: white;"><img src="img/ranks/rank' . char_get_pvp_rank_id($char['totalHonorPoints'], char_get_side_id($char['race'])) . '.gif" alt="" /></span>
                            </td>
                            <td>
                                <a href="guild.php?action=view_guild&amp;error=3&amp;id=' . $char['guildid'] . '">' . htmlentities($guild_name) . '</a>
                            </td>
                            <td><span onmousemove="toolTip(\'MapID:' . $char['map'] . '\', \'item_tooltip\')" onmouseout="toolTip()">' . get_map_name($char['map'], $sqlm) . '</span></td>
                            <td><span onmousemove="toolTip(\'ZoneID:' . $char['zone'] . '\', \'item_tooltip\')" onmouseout="toolTip()">' . get_zone_name($char['zone'], $sqlm) . '</span></td>';
            if ($showcountryflag) {
                $country = misc_get_country_by_account($char['account'], $sqlr, $sqlm);
                $output .= '
                            <td>' . ($country['code'] ? '<img src="img/flags/' . $country['code'] . '.png" onmousemove="toolTip(\'' . $country['country'] . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" />' : '-') . '</td>';
            }
            $output .= '
                        </tr>';
        }
        $output .= '
                        <tr>';
        $output .= '
                            <td colspan="' . (10 - $showcountryflag) . '" align="right" class="hidden" width="25%">';
        $output .= generate_pagination('index.php?start_m=' . $start_m . '&amp;order_by=' . $order_by . '&amp;dir=' . ($dir ? 0 : 1), $total_online, $itemperpage, $start);
        unset($total_online);
        $output .= '
                            </td>
                        </tr>
                    </table>
                    <br />
                </center>';
    }
}
开发者ID:BACKUPLIB,项目名称:minimanager,代码行数:101,代码来源:index.php

示例15: htmlentities

$output .= '
    <div id="tab">
        <ul>
            <li><a href="char.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['char_sheet'] . '</a></li>
            <li><a href="char_inv.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['inventory'] . '</a></li>
            <li><a href="char_extra.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['extra'] . '</a></li>
            ' . ($char['level'] < 10 ? '' : '<li><a href="char_talent.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['talents'] . '</a></li>') . '
            <li><a href="char_achieve.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['achievements'] . '</a></li>
            <li><a href="char_rep.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['reputation'] . '</a></li>
            <li><a href="char_skill.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['skills'] . '</a></li>
            <li><a href="char_quest.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['quests'] . '</a></li>';
if (char_get_class_name($char['class']) === 'Hunter') {
    $output .= '
            <li><a href="char_pets.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['pets'] . '</a></li>';
}
$output .= '
            <li><a href="char_friends.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['friends'] . '</a></li>
            <li><a href="char_spell.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['spells'] . '</a></li>
            <li><a href="char_mail.php?id=' . $id . '&amp;realm=' . $realmid . '">' . $lang_char['mail'] . '</a></li>
        </ul>
    </div>';
$output .= '
    <div id="tab_content2">
        <font class="bold">
            ' . htmlentities($char['name']) . ' -
            <img src="img/c_icons/' . $char['race'] . '-' . $char['gender'] . '.gif"
            onmousemove="toolTip(\'' . char_get_race_name($char['race']) . '\', \'item_tooltip\')" onmouseout="toolTip()" alt="" />
            <img src="img/c_icons/' . $char['class'] . '.gif"
            onmousemove="toolTip(\'' . char_get_class_name($char['class']) . '\',\'item_tooltip\')" onmouseout="toolTip()" alt="" /> - lvl ' . char_get_level_color($char['level']) . '
        </font>';
开发者ID:BACKUPLIB,项目名称:minimanager,代码行数:30,代码来源:char_header.php


注:本文中的char_get_level_color函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。