/** * Make a table for the configuration page of the plugin system * * Now the code must be: * AdmPlugin($name_of_the_plugin, $description); * @author adri93 */ function AdmPlugin($name, $desc) { $page = $_GET['modo']; if (is_phpself('adm/SettingsPage') && $page == 'plugins') { $activado = PluginAct($name); $config_line .= "<tr>"; if ($activado == "1") { //if the plugin is on $config_line .= "<td class=\"c\" style=\"color:#FFFFFF\">" . $name . "</td>"; $config_line .= "<td align=\"left\" class=\"c\" style=\"color:green\"><b>On</b></td>"; $config_line .= "<td align=\"center\" class=\"c\" width=\"20px\" style=\"color:#FFFFFF\"><a href=\"SettingsPage.php?modo=plugins&desactivate=" . $name . "\">Desactivar</a></td>"; } else { //if the plugin is off $config_line .= "<td class=\"c\" style=\"color:#FFFFFF\"><a href=\"#\" onMouseOver='return overlib(\"" . $desc . "\", CENTER, OFFSETX, 120, OFFSETY, -40, WIDTH, 250);' onMouseOut='return nd();' class=\"big\">" . $name . "</a></td>"; $config_line .= "<td align=\"left\" class=\"c\" style=\"color:red\"><b>Off</b></td>"; $config_line .= "<td align=\"center\" class=\"c\" width=\"20px\" style=\"color:#FFFFFF\"><a href=\"SettingsPage.php?modo=plugins&activate=" . $name . "\">Activar</a></td>"; } $config_line .= "</tr>"; } return $config_line; }
} if ($ticket2['status'] == 3) { $status = "<font color=green>Respuesta del Jugador</font>"; } $parse['tickets'] .= "<tr>" . "<td class='b'>" . $ticket2['ID'] . "</td>" . "<td class='b'>" . $ticket2['subject'] . "</td>" . "<td class='b'>" . $status . "</td>" . "<td class='b'>" . date("j-m-Y H:i:s", $ticket2['time']) . "</td>" . "</tr>"; $parse['text_view'] = $ticket2['text']; $parse['ids'] = $ticket2['ID']; display(parsetemplate(gettemplate('plugins/supp/supp_detail'), $parse)); } } } ShowSupportPage($user); } //adm menu hack $lang['mu_connected'] .= '</a></th></tr><tr><th onMouseOver=\'this.className="ForIEHover"\' onMouseOut=\'this.className="ForIE"\' class="ForIE"><a href="SettingsPage.php?page=support" target="Hauptframe">Soporte'; if (is_phpself('adm/SettingsPage') && $page == 'support') { include 'AdminFunctions/Autorization.' . $phpEx; if ($user['authlevel'] >= 1) { includeLang('INGAME'); $parse = $lang; if ($_GET['ticket'] == 0) { /// Deteilsanzeige des eigenen tickets $query = doquery("SELECT s.* ,u.id, u.username as username FROM {{table}}supp as s, {{table}}users as u WHERE status >= '1' AND u.id=s.player_id ORDER BY s.time", ""); while ($ticket = mysql_fetch_array($query)) { if ($ticket['status'] == 1) { $status = "<font color=green>Abrir</font>"; } if ($ticket['status'] == 0) { $status = "<font color=red>Cerrar</font>"; } if ($ticket['status'] == 2) {
* @name Records Plugin * @author adri93 (plugin) * @author Algun frances de Xnova Project y diversas personas en la mejora del codigo * @category Plugin * @version 0.3 * @uses Plugin system 0.3 * @copyright (c) 2010 Adri93 for the plugin conversion and other some people for the records page code. * @license http://opensource.org/licenses/gpl-license.php GNU Public License */ $rec_name = "Records"; $rec_desc = "Qui&aecute;n a conseguido más de algo?"; $config_line .= AdmPlugin($rec_name, $rec_desc); if (PluginAct($rec_name) == 1) { $lang['lm_statistics'] .= '</a></font></div></td></tr><tr><td><div align="center"><font color="#FFFFFF"><a href="game.php?page=records">Records'; $page = $_GET['page']; if (is_phpself('game') && $page == 'records') { //funciones básicas include $game_root . 'includes/functions/SortUserPlanets.' . $phpEx; $dpath = !$user["dpath"] ? DEFAULT_SKINPATH : $user["dpath"]; include $game_root . 'includes/functions/SetSelectedPlanet.' . $phpEx; SetSelectedPlanet($user); $planetrow = doquery("SELECT * FROM `{{table}}` WHERE `id` = '" . $user['current_planet'] . "';", "planets", true); include $game_root . 'includes/functions/CheckPlanetUsedFields.' . $phpEx; CheckPlanetUsedFields($planetrow); //fin funciones basicas $RecordTpl = gettemplate('plugins/record/record_body'); $HeaderTpl = gettemplate('plugins/record/record_section_header'); $TableRows = gettemplate('plugins/record/record_section_rows'); $lang['rec_rien'] = "Vacio"; $parse['rec_title'] = $lang['rec_title']; $bloc['section'] = $lang['rec_build'];