?> </td> </tr> <?php } ?> </table> <?php include 'pagination.php'; ?> <div> </div><a href="<?php echo OS_HOME; ?> adm/?bnet_pm" class="menuButtons">BNet PM</a><div> </div><?php } else { if (isset($_GET["purge_pm"]) and OS_IsRoot()) { $sth = $db->prepare("TRUNCATE TABLE " . OSDB_BNET_PM . " "); $result = $sth->execute(); ?> <div align="center"> <h2>All messages are deleted successfully.</h2> <a href="<?php echo OS_HOME; ?> adm/?bnet_pm">Refresh page</a> to continue. </div> <?php } $sth = $db->prepare("SELECT COUNT(*) FROM " . OSDB_BNET_PM . ""); $result = $sth->execute(); $r = $sth->fetch(PDO::FETCH_NUM);
$date = EscapeStr(trim($_POST["date"])); $expire = EscapeStr(trim($_POST["expire"])); $warn = EscapeStr(trim($_POST["warn"])); if (empty($ip)) { $sth = $db->prepare("SELECT * FROM " . OSDB_GP . " WHERE name = '" . $name . "' AND ip!='' LIMIT 1"); $result = $sth->execute(); $row = $sth->fetch(PDO::FETCH_ASSOC); $ip = $row["ip"]; } if (date("Y", strtotime($expire)) <= 1990) { $expire = ""; } if (strlen($name) <= 2) { $errors .= "<div>Field Name does not have enough characters</div>"; } if (!OS_IsRoot() and strstr($ip, ":")) { $errors .= "<div style='color: #ab0900; font-weight:bold;'><img src='del.png' alt='delete' width='16' height='16' class='imgvalign' /> You don't have permission to ban IP range</div>"; } $time = date("Y-m-d H:i:s", time()); if (!empty($ip) and $GeoIP == 1) { $Letter = geoip_country_code_by_addr($GeoIPDatabase, $ip); //$Country = geoip_country_name_by_addr($GeoIPDatabase, $ip); $country = $Letter; } else { $country = ""; } if (isset($_GET["edit"])) { $sql = "UPDATE " . OSDB_BANS . " SET \n\t name= '" . $name . "', server = '" . $server . "', reason = '" . $reason . "', ip='" . $ip . "', ip_part='" . $ip_part . "', admin = '" . $admin . "', gamename='" . $gn . "', expiredate='" . $expire . "', warn = '" . $warn . "', date='" . $date . "', country = '" . $country . "' WHERE id ='" . $id . "' LIMIT 1 "; //$sql2 = "UPDATE ".OSDB_GO. " SET player_name = '".$name."', reason = '".$reason."', offence_expire = //'".$expire."', pp = '".$warn."', admin = '".$admin."' //WHERE player_name='".$name."' AND offence_time = '".$date."' "; }
<?php include "../config.php"; $time = microtime(); $time = explode(' ', $time); $time = $time[1] + $time[0]; $start = $time; include "../inc/common.php"; require_once '../lang/' . $default_language . '.php'; if (isset($_GET["plugins"]) and !OS_IsRoot()) { if (isset($_GET["edit"]) or isset($_GET["disable"]) or isset($_GET["enable"]) or isset($_GET["delete"])) { header("location: " . OS_HOME . "adm/?plugins&access=0"); } } include "../inc/class.db.PDO.php"; //include("../inc/class.database.php"); //$DBDriver ="mysql"; include "../inc/db_connect.php"; if (file_exists('../themes/' . $DefaultStyle . '/functions.php')) { include '../themes/' . $DefaultStyle . '/functions.php'; } include "admin_func.php"; include "admin_sys.php"; ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <meta http-equiv="content-style-type" content="text/css" /> <meta name="author" content="Ivan Antonijevic" />
$PluginName = ""; $PluginAuthor = ""; $PluginDesc = ""; if ($PluginFile != "." and $PluginFile != "index.php" and $PluginFile != ".." and strstr($PluginFile, ".php") == true) { //enable/disable if (isset($_GET["disable"]) and file_exists($plugins_dir . safeEscape($_GET["disable"])) and $PluginFile == $_GET["disable"] and OS_IsRoot()) { $PluginEnabled = 1; write_value_of('$PluginEnabled', "{$PluginEnabled}", 0, $plugins_dir . safeEscape($_GET["disable"])); echo $PluginFile . ' - disabled <a href="' . OS_HOME . 'adm/?plugins">« Back</a>'; } else { if (isset($_GET["enable"]) and file_exists($plugins_dir . safeEscape($_GET["enable"])) and $PluginFile == $_GET["enable"] and OS_IsRoot()) { $PluginEnabled = 0; write_value_of('$PluginEnabled', "{$PluginEnabled}", 1, $plugins_dir . safeEscape($_GET["enable"])); echo $PluginFile . ' - enabled <a href="' . OS_HOME . 'adm/?plugins">« Back</a>'; } else { if (isset($_GET["delete"]) and file_exists($plugins_dir . safeEscape($_GET["delete"])) and OS_IsRoot()) { $PluginEnabled = 0; unlink($plugins_dir . safeEscape($_GET["delete"])); } } } if (file_exists($plugins_dir . $PluginFile)) { $PluginName = trim(str_replace("//Plugin:", "", OS_ReadLine($plugins_dir . $PluginFile, 2))); $PluginAuthor = trim(str_replace("//Author:", "", OS_ReadLine($plugins_dir . $PluginFile, 3))); $PluginDesc = trim(str_replace("//", "", OS_ReadLine($plugins_dir . $PluginFile, 4))); if (!empty($PluginName) and !empty($PluginAuthor)) { include $plugins_dir . $PluginFile; if (isset($PluginOptions) and $PluginOptions == 1 and $PluginEnabled == 1) { $PluginEdit = '<a href="' . OS_HOME . 'adm/?plugins&edit=' . $PluginFile . '#' . $PluginFile . '"><img src="' . OS_HOME . 'adm/edit.png" alt="edit" width="16" height="16" /> Edit</a>'; if (isset($_GET["edit"]) and $_GET["edit"] == $PluginFile) { $PluginEdit = '<a href="' . OS_HOME . 'adm/?plugins#' . $PluginFile . '"><img src="' . OS_HOME . 'adm/edit.png" alt="edit" width="16" height="16" /> « Edit</a>';
if (isset($_GET["live_games"])) { include 'admin_live_games.php'; } else { if (isset($_GET["bnet_pm"])) { include 'admin_bnet_pm.php'; } else { if (isset($_GET["word_filter"])) { include 'admin_word_filter.php'; } else { if (isset($_GET["pp"])) { include 'admin_pp.php'; } else { if (isset($_GET["announcements"])) { include 'admin_announcements.php'; } else { if (isset($_GET["ban_email"]) and OS_IsRoot()) { include 'admin_ban_email.php'; } else { if (isset($_GET["geoip"])) { include 'admin_geoip.php'; } else { if (isset($_GET["admin_logs"]) and $_SESSION["level"] >= 10) { include 'admin_logs.php'; } else { if (isset($_GET["warns"])) { include 'admin_warns.php'; } else { if (isset($_GET["aliases"])) { include 'admin_aliases.php'; } else { if (isset($_GET["ban_names"])) {
<input type="hidden" name="id" value="<?php echo $row["id"]; ?> " /> <?php if (isset($_GET["page"]) and is_numeric($_GET["page"])) { ?> <input type="hidden" name="page" value="<?php echo (int) $_GET["page"]; ?> " /> <?php } ?> <?php if (!OS_IsRoot()) { $dis = "disabled"; } else { $dis = ""; } ?> <input <?php echo $dis; ?> type="text" size="10" value="<?php echo $row["points"]; ?> " name="points" /> <input <?php echo $dis; ?>
<?php die("Deprecated!"); //Deprecated $time = microtime(); $time = explode(' ', $time); $time = $time[1] + $time[0]; $start = $time; include "../config.php"; include '../lang/' . $default_language . '.php'; include "../inc/common.php"; if (OS_is_logged() and OS_IsRoot()) { //include("../inc/class.database.php"); require_once '../inc/class.db.PDO.php'; include "../inc/db_connect.php"; if (file_exists('../' . OS_CURRENT_THEME_PATH . '/functions.php')) { include '../' . OS_CURRENT_THEME_PATH . '/functions.php'; } $return = ""; function OS_UpdateScoresTable($name = "") { global $db; $name = OS_StrToUTF8(trim($name)); if (!empty($name)) { $sth = $db->prepare("SELECT * FROM scores WHERE (name) = ('" . $name . "')"); $result = $sth->execute(); if ($limit = $sth->rowCount() <= 0) { $sth = $db->prepare("INSERT INTO scores(category, name)VALUES('dota_elo','" . $name . "')"); $result = $sth->execute(); } //Get updated result
adm/?word_filter">Word Filter</a></li> <li><a href="<?php echo OS_HOME; ?> adm/?gamelist">Gamelist</a></li> <li><a href="<?php echo OS_HOME; ?> adm/?live_games">Live Games</a></li> <li><a href="<?php echo OS_HOME; ?> adm/?remote">Remote Control</a></li> --> <?php if (OS_IsRoot()) { ?> <li><a href="<?php echo OS_HOME; ?> adm/?bnet_pm">BNET PM</a></li> <?php } ?> <li><a href="<?php echo OS_HOME; ?> adm/?heroes"><?php echo $lang["heroes"]; ?> </a></li>
<h2>User successfully deleted. <a href="<?php echo OS_HOME; ?> adm/?users">« Back</a></h2> </div> <?php } //eDIT if (!OS_IsRoot() and isset($_GET["edit"]) and is_numeric($_GET["edit"]) or isset($_GET["add"]) and !OS_IsRoot() or isset($_GET["del"]) and is_numeric($_GET["del"]) and !OS_IsRoot()) { ?> <div align="center" style="margin-bottom: 60px;"> <h2>You don't have permission to access this page</h2> </div> <?php } else { if (OS_IsRoot() and isset($_GET["edit"]) and is_numeric($_GET["edit"]) or isset($_GET["add"])) { $name = ""; $email = ""; $bnet = ""; if (isset($_GET["edit"]) and is_numeric($_GET["edit"])) { $id = safeEscape((int) $_GET["edit"]); } else { $id = 0; } //UPDATE if (isset($_POST["edit_user"])) { $name = safeEscape($_POST["name"]); $bnet = safeEscape($_POST["bnet"]); $bnet = strtolower($bnet); $email = safeEscape($_POST["email"]); //if not root admin do not change access level