示例#1
0
 public function select($intIDNum, $numericIDOnly = true)
 {
     $returnVal = parent::select($intIDNum, $numericIDOnly);
     if ($returnVal) {
         $this->arrSelectValues = $this->getAssociateIDs("ORDER BY componentvalue");
     }
     return $returnVal;
 }
示例#2
0
 public function delete()
 {
     $returnVal = false;
     if ($this->intTableKeyValue != "") {
         $info = $this->arrObjInfo;
         if (parent::delete()) {
             deleteFile(BASE_DIRECTORY . $info['icon']);
             $returnVal = true;
         }
     }
     return $returnVal;
 }
示例#3
0
<?php

/*
 * Bluethrust Clan Scripts v4
 * Copyright 2014
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include_once "../../../../_setup.php";
include_once "../../../../classes/member.php";
include_once "../../../../classes/basicorder.php";
$consoleObj = new ConsoleOption($mysqli);
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$cID = $consoleObj->findConsoleIDByName("Member Application");
$consoleObj->select($cID);
$appComponentObj = new BasicOrder($mysqli, "app_components", "appcomponent_id");
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    $memberInfo = $member->get_info_filtered();
    if ($appComponentObj->select($_POST['acID'])) {
        $member->logAction("Modified the member application component order.");
        $appComponentObj->move($_POST['acDir']);
        include "appcomponentlist.php";
    }
}
    // Check Login
    if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
        $memberInfo = $member->get_info();
    } else {
        exit;
    }
} else {
    $memberInfo = $member->get_info();
    $consoleObj->select($consoleObj->findConsoleIDByName("Manage Diplomacy Statuses"));
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
echo "\n<table class='formTable' style='border-spacing: 0px; margin-top: 0px'>\n\t<tr><td colspan='5' class='dottedLine'></td></tr>\n";
if (!isset($diplomacyStatusObj)) {
    $diplomacyStatusObj = new BasicOrder($mysqli, "diplomacy_status", "diplomacystatus_id");
}
$counter = 0;
$x = 1;
$intHighestOrder = $diplomacyStatusObj->getHighestOrderNum();
$result = $mysqli->query("SELECT * FROM " . $dbprefix . "diplomacy_status ORDER BY ordernum DESC");
while ($row = $result->fetch_assoc()) {
    if ($counter == 1) {
        $addCSS = " alternateBGColor";
        $counter = 0;
    } else {
        $addCSS = "";
        $counter = 1;
    }
    if ($x == 1) {
        $dispUpArrow = "<img src='" . $MAIN_ROOT . "images/transparent.png' width='24' height'24'>";
示例#5
0
}
// Start Page
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Private Messages");
$consoleObj->select($cID);
$consoleInfo = $consoleObj->get_info_filtered();
$consoleTitle = $consoleInfo['pagetitle'];
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$PAGE_NAME = "Compose Message - " . $consoleTitle . " - ";
$dispBreadCrumb = "<a href='" . $MAIN_ROOT . "'>Home</a> > <a href='" . $MAIN_ROOT . "members'>My Account</a> > <a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "'>" . $consoleTitle . "</a> > Compose Message";
$EXTERNAL_JAVASCRIPT .= "\n<script type='text/javascript' src='" . $MAIN_ROOT . "members/js/console.js'></script>\n<script type='text/javascript' src='" . $MAIN_ROOT . "members/js/main.js'></script>\n\n<style>\n\t.ui-autocomplete {\n\t\tmax-height: 150px;\n\t\toverflow-y: auto;\n\t}\n</style>\n";
$prevFolder = "../../";
include "../../themes/" . $THEME . "/_header.php";
echo "\n<div class='breadCrumbTitle' id='breadCrumbTitle'>Compose Message</div>\n<div class='breadCrumb' id='breadCrumb' style='padding-top: 0px; margin-top: 0px'>\n{$dispBreadCrumb}\n</div>\n";
$pmObj = new BasicOrder($mysqli, "privatemessages", "pm_id");
$rankCatObj = new RankCategory($mysqli);
$squadObj = new Squad($mysqli);
$tournamentObj = new Tournament($mysqli);
$multiMemPMObj = new Basic($mysqli, "privatemessage_members", "pmmember_id");
$pmObj->set_assocTableName("privatemessage_members");
$pmObj->set_assocTableKey("member_id");
// Check Login
$LOGIN_FAIL = true;
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    $memberInfo = $member->get_info_filtered();
    $dispError = "";
    $countErrors = 0;
    if ($_POST['submit']) {
        $pmSessionID = $_POST['pmsessionid'];
        // Check To
示例#6
0
 *
 */
include_once "../classes/basicorder.php";
if (!isset($member) || substr($_SERVER['PHP_SELF'], -11) != "console.php") {
    exit;
} else {
    $memberInfo = $member->get_info();
    $consoleObj->select($_GET['cID']);
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
$cID = $_GET['cID'];
$dispError = "";
$countErrors = 0;
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
if ($_POST['submit']) {
    // Check Name
    if (trim($_POST['catname']) == "") {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> Category name may not be blank.<br>";
        $countErrors++;
    }
    // Check Order
    $intNewOrderSpot = $categoryObj->validateOrder($_POST['displayorder'], $_POST['beforeafter']);
    if ($intNewOrderSpot === false) {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> You selected an invalid display order.<br>";
        $countErrors++;
    }
    if ($countErrors == 0) {
示例#7
0
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
$prevFolder = "../../../../";
include_once $prevFolder . "_setup.php";
$consoleObj = new ConsoleOption($mysqli);
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$cID = $consoleObj->findConsoleIDByName("Member Application");
$consoleObj->select($cID);
$appComponentObj = new BasicOrder($mysqli, "app_components", "appcomponent_id");
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    include BASE_DIRECTORY . "members/include/membermanagement/include/appcomponent_form.php";
    if ($_POST['saveComponent']) {
        // Check Component Name
        if (trim($_POST['newComponentName']) == "") {
            $addAppForm->errors[] = "You can't have a blank component name.<br>";
        }
        if (!in_array($_POST['newComponentType'], array_keys($typeOptions))) {
            $addAppForm->errors[] = "You selected an invalid component type.<br>";
        }
        if (count($addAppForm->errors) == 0) {
            if ($appComponentObj->getHighestOrderNum() == "") {
                $componentOrderNum = $appComponentObj->validateOrder("first", "before");
            } else {
                $appComponentObj->selectByOrder(1);
示例#8
0
<?php

/*
 * Bluethrust Clan Scripts v4
 * Copyright 2014
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
$diplomacyStatusObj = new BasicOrder($mysqli, "diplomacy_status", "diplomacystatus_id");
if (!isset($member) || substr($_SERVER['PHP_SELF'], -11) != "console.php" || !$diplomacyStatusObj->select($_GET['sID'])) {
    echo "hi";
    exit;
}
$diplomacyStatusInfo = $diplomacyStatusObj->get_info_filtered();
if ($_POST['submit']) {
    // Check Name
    if (trim($_POST['statusname']) == "") {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> Status name may not be blank.<br>";
        $countErrors++;
    }
    // Check Display Order
    $intNewOrderNum = $diplomacyStatusObj->validateOrder($_POST['displayorder'], $_POST['beforeafter'], true, $diplomacyStatusInfo['ordernum']);
    if ($intNewOrderNum === false) {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> You selected an invalid display order.<br>";
        $countErrors++;
    }
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include_once "../../../../_setup.php";
include_once "../../../../classes/member.php";
include_once "../../../../classes/basicorder.php";
$consoleObj = new ConsoleOption($mysqli);
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$cID = $consoleObj->findConsoleIDByName("Member Application");
$consoleObj->select($cID);
$appComponentObj = new BasicOrder($mysqli, "app_components", "appcomponent_id");
$appComponentObj->set_assocTableName("app_selectvalues");
$appComponentObj->set_assocTableKey("appselectvalue_id");
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    if ($appComponentObj->select($_POST['acID'])) {
        $arrCompInfo = $appComponentObj->get_info_filtered();
        if (!$_POST['confirmDelete']) {
            echo "\n\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\tAre you sure you want to delete <b>" . $arrCompInfo['name'] . "</b> from the member application?\n\t\t\t\t</p>\n\t\t\t";
        } elseif ($_POST['confirmDelete']) {
            if ($appComponentObj->delete()) {
                $appComponentObj->resortOrder();
                $member->logAction("Deleted a member application component.");
                echo "\n\t\t\t\t\t\n\t\t\t\t\t<div id='confirmDeleteMessage' style='display: none'>\n\t\t\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\t\t\t<b>" . $arrCompInfo['name'] . "</b> was successfully deleted from the member application!\n\t\t\t\t\t\t</p>\n\t\t\t\t\t</div>\n\t\t\t\t\t\n\t\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\t\t\n\t\t\t\t\t\tfunction reloadAppCompList() {\n\t\t\t\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\$('#loadingSpiral').show();\n\t\t\t\t\t\t\t\t\$('#appComponentList').fadeOut(250);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "members/include/membermanagement/include/appcomponentlist.php', { }, function(data) {\n\t\t\t\t\t\t\t\t\t\$('#appComponentList').html(data);\n\t\t\t\t\t\t\t\t\t\$('#loadingSpiral').hide();\n\t\t\t\t\t\t\t\t\t\$('#appComponentList').fadeIn(250);\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t</script>\n\t\t\t\t\t";
            } else {
                echo "\n\t\t\t\t\n\t\t\t\t\t<div id='confirmDeleteMessage' style='display: none'>\n\t\t\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\t\t\tUnable to delete <b>" . $arrCompInfo['name'] . "</b> from the member application!  You may need to delete it manually.\n\t\t\t\t\t\t</p>\n\t\t\t\t\t</div>\n\t\t\t\t\n\t\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\t\tfunction reloadAppCompList() {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t</script>\n\t\t\t\t\t\n\t\t\t\t";
            }
示例#10
0
<?php

include "../_setup.php";
include_once "../classes/member.php";
include_once "../classes/basicorder.php";
$member = new Member($mysqli);
$appComponentObj = new BasicOrder($mysqli, "app_components", "appcomponent_id");
$appComponentObj->set_assocTableName("app_selectvalues");
$appComponentObj->set_assocTableKey("appselectvalue_id");
if ($_GET['appCompID'] != -1 && !$appComponentObj->select($_GET['appCompID']) || $_GET['appCompID'] != -1 && ($appComponentObj->get_info("componenttype") != "captcha" && $appComponentObj->get_info("componenttype") != "captchaextra")) {
    exit;
}
if (isset($_GET['display'])) {
    echo "<img src='" . $MAIN_ROOT . "images/captcha.php?appCompID=" . $_GET['appCompID'] . "&new=" . time() . "' width='440' height='90'>";
} else {
    header('Content-Type: image/png');
    if ($_GET['appCompID'] == -1) {
        $appCompInfo['appcomponent_id'] = -1;
    } else {
        $appCompInfo = $appComponentObj->get_info_filtered();
    }
    $captchaObj = new Basic($mysqli, "app_captcha", "appcaptcha_id");
    $filterIP = $mysqli->real_escape_string($IP_ADDRESS);
    $mysqli->query("DELETE FROM " . $dbprefix . "app_captcha WHERE appcomponent_id = '" . $appCompInfo['appcomponent_id'] . "' AND ipaddress = '" . $filterIP . "'");
    // Create the image
    $im = imagecreatetruecolor(440, 90);
    // Colors
    $black = imagecolorallocate($im, 9, 9, 9);
    $blackAlpha = imagecolorallocatealpha($im, 9, 9, 9, 25);
    $redAlpha = imagecolorallocatealpha($im, 255, 0, 0, 15);
    $white = imagecolorallocate($im, 255, 255, 255);
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
if (!isset($member) || substr($_SERVER['PHP_SELF'], -11) != "console.php" || !isset($_GET['cID'])) {
    include_once "../../../../_setup.php";
    include_once "../../../../classes/member.php";
    // Start Page
    $consoleObj = new ConsoleOption($mysqli);
    $cID = $consoleObj->findConsoleIDByName("Manage Forum Categories");
    $intAddCategoryCID = $consoleObj->findConsoleIDByName("Add Forum Category");
    $consoleObj->select($cID);
    $consoleInfo = $consoleObj->get_info_filtered();
    $member = new Member($mysqli);
    $member->select($_SESSION['btUsername']);
    $categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
    $categoryObj->set_assocTableName("forum_board");
    $categoryObj->set_assocTableKey("forumboard_id");
    // Check Login
    if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
        $memberInfo = $member->get_info();
    } else {
        exit;
    }
} else {
    $memberInfo = $member->get_info();
    $consoleObj->select($consoleObj->findConsoleIDByName("Manage Forum Categories"));
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
示例#12
0
            echo "<option value='" . $boardInfo['forumboard_id'] . "'>" . str_repeat("&nbsp;&nbsp;&nbsp;", $indent) . "&middot; " . $boardInfo['name'] . "</option>";
            $moreSubForums = $boardObj->getSubForums();
            if (count($moreSubForums) > 0) {
                listSubForums($value, $filterOut, $indent + 1);
            }
        }
    }
}
// Start Page
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Add Board");
$consoleObj->select($cID);
$consoleInfo = $consoleObj->get_info_filtered();
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
$boardObj = new ForumBoard($mysqli);
// Check Login
$LOGIN_FAIL = true;
$arrSelectBoard = "";
if (isset($_POST['bID']) && $boardObj->select($_POST['bID'])) {
    $arrSelectBoard = $boardObj->findBeforeAfter();
    if ($boardObj->get_info("subforum_id") != 0) {
        $arrSelectBoard[0] = $boardObj->get_info("subforum_id");
    }
} else {
    $_POST['bID'] = "";
}
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
示例#13
0
 public function get_info_filtered($returnSingleValue = "")
 {
     global $MAIN_ROOT;
     $result = parent::get_info_filtered($returnSingleValue);
     if (substr($result['imageurl'], 0, 4) != "http") {
         if ($returnSingleValue == "") {
             $fullImageURL = $MAIN_ROOT . $result['imageurl'];
             $result['imageurl'] = $fullImageURL;
         } elseif ($returnSingleValue == "imageurl") {
             $fullImageURL = $MAIN_ROOT . $result;
             $result = $fullImageURL;
         }
     }
     return $result;
 }
示例#14
0
 * Bluethrust Clan Scripts v4
 * Copyright 2014
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
if (!isset($member) || substr($_SERVER['PHP_SELF'], -11) != "console.php") {
    exit;
} else {
    $memberInfo = $member->get_info();
    $consoleObj->select($_GET['cID']);
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
$cID = $_GET['cID'];
$intAddCategoryCID = $consoleObj->findConsoleIDByName("Add Forum Category");
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
if ($categoryObj->select($_GET['catID']) && $_GET['action'] == "edit") {
    include "include/edit_category.php";
} else {
    echo "\n\t\n\t\t<table class='formTable'>\n\t\t\t<tr>\n\t\t\t\t<td class='main' colspan='2' align='right'>\n\t\t\t\t\t&raquo; <a href='" . $MAIN_ROOT . "members/console.php?cID=" . $intAddCategoryCID . "'>Add Forum Category</a> &laquo;<br><br>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td class='formTitle' style='width: 76%'>Category Name:</td>\n\t\t\t\t<td class='formTitle' style='width: 24%'>Actions:</td>\n\t\t\t</tr>\n\t\t</table>\n\t\n\t\t<div id='loadingSpiral' class='loadingSpiral'>\n\t\t\t<p align='center'>\n\t\t\t\t<img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/loading-spiral.gif'><br>Loading\n\t\t\t</p>\n\t\t</div>\n\t\t\n\t\t\n\t\t<div id='categoryList'>\n\t";
    include "include/main_managecategory.php";
    echo "\n\t\t</div>\n\t\t<div id='deleteCatDiv' style='display: none'></div>\n\t\t<script type='text/javascript'>\n\t\t\n\t\t\tfunction moveCat(strDir, intCatID) {\n\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\$('#loadingSpiral').show();\n\t\t\t\t\t\$('#categoryList').fadeOut(250);\n\t\t\t\t\t\$.post('" . $MAIN_ROOT . "members/include/forum/include/move_category.php', { catID: intCatID, cDir: strDir }, function(data) {\n\t\t\t\t\t\t\$('#categoryList').html(data);\n\t\t\t\t\t\t\$('#loadingSpiral').hide();\n\t\t\t\t\t\t\$('#categoryList').fadeIn(250);\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t}\n\t\t\n\t\t\n\t\t\tfunction deleteCat(intCatID) {\n\t\t\t\n\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\n\t\t\t\t\t\$.post('" . $MAIN_ROOT . "members/include/forum/include/delete_category.php', { catID: intCatID }, function(data) {\n\t\t\t\t\t\n\t\t\t\t\t\t\$('#deleteCatDiv').html(data);\n\t\t\t\t\t\n\t\t\t\t\t});\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t}\n\t\t</script>\n\t\t\n\t";
}
示例#15
0
<?php

/*
 * Bluethrust Clan Scripts v4
 * Copyright 2014
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include "../../../../_setup.php";
include_once "../../../../classes/member.php";
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Manage Forum Categories");
$consoleObj->select($cID);
if ($member->authorizeLogin($_SESSION['btPassword'])) {
    $memberInfo = $member->get_info_filtered();
    if (($memberInfo['rank_id'] == 1 || $member->hasAccess($consoleObj)) && $categoryObj->select($_POST['catID'])) {
        define('MEMBERRANK_ID', $memberInfo['rank_id']);
        $categoryObj->move($_POST['cDir']);
        include "main_managecategory.php";
    }
}
示例#16
0
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
$prevFolder = "../../../../";
include_once $prevFolder . "_setup.php";
$consoleObj = new ConsoleOption($mysqli);
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$cID = $consoleObj->findConsoleIDByName("Member Application");
$consoleObj->select($cID);
$appComponentObj = new BasicOrder($mysqli, "app_components", "appcomponent_id");
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    if ($appComponentObj->select($_POST['appCompID'])) {
        $appCompInfo = $appComponentObj->get_info_filtered();
        $appComponentObj->set_assocTableName("app_selectvalues");
        $appComponentObj->set_assocTableKey("appselectvalue_id");
        include BASE_DIRECTORY . "members/include/membermanagement/include/appcomponent_form.php";
        if ($_POST['saveComponent']) {
            // Check Component Name
            if (trim($_POST['saveComponentName']) == "") {
                $addAppForm->errors[] = "You can't have a blank component name.<br>";
            }
            if (!in_array($_POST['saveComponentType'], array_keys($typeOptions))) {
                $addAppForm->errors[] .= "You selected an invalid component type.<br>";
            }
            if (count($addAppForm->errors) == 0) {
示例#17
0
 public function delete()
 {
     $returnVal = false;
     if ($this->intTableKeyValue != "") {
         $info = $this->arrObjInfo;
         $returnVal = parent::delete();
         deleteFile(BASE_DIRECTORY . $info['imageurl']);
     }
 }
示例#18
0
 * License: http://www.bluethrust.com/license.php
 *
 */
include_once "../../../../_setup.php";
include_once "../../../../classes/member.php";
include_once "../../../../classes/basicorder.php";
include_once "../../../../classes/forumboard.php";
// Start Page
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Manage Moderators");
$consoleObj->select($cID);
$consoleInfo = $consoleObj->get_info_filtered();
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$memberModObj = new Member($mysqli);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
$boardObj = new ForumBoard($mysqli);
// Check Login
$LOGIN_FAIL = true;
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    echo "\n\t\n\t\t<table class='formTable' style='margin-bottom: 20px'>\n\t\t\t<tr>\n\t\t\t\t<td class='formTitle' style='width: 50%'>Board:</td>\n\t\t\t\t<td class='formTitle' style='width: 35%'>Date Added:</td>\n\t\t\t\t<td class='formTitle' style='width: 15%'>Actions:</td>\n\t\t\t</tr>\n\t\n\t";
    if (isset($_POST['mID']) && $memberModObj->select($_POST['mID'])) {
        $memberModInfo = $memberModObj->get_info_filtered();
        if ($_POST['action'] == "add") {
            if (substr($_POST['bID'], 0, 4) == "cat_") {
                $catID = str_replace("cat_", "", $_POST['bID']);
                if ($categoryObj->select($catID)) {
                    $arrBoards = $categoryObj->getAssociateIDs();
                    foreach ($arrBoards as $boardID) {
示例#19
0
/*
 * Bluethrust Clan Scripts v4
 * Copyright 2014
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include "../../../../_setup.php";
include_once "../../../../classes/member.php";
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Manage Forum Categories");
$consoleObj->select($cID);
if ($member->authorizeLogin($_SESSION['btPassword']) && $categoryObj->select($_POST['catID'])) {
    $categoryInfo = $categoryObj->get_info_filtered();
    $arrBoards = $categoryObj->getAssociateIDs();
    if (count($arrBoards) > 0) {
        echo "\n\t\t\n\t\t\t<div id='deleteMessage' style='display: none'>\n\t\t\t\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\tThere are currently boards with the category, <b>" . $categoryInfo['name'] . "</b>.  You must move these boards to a different category before deleting.\n\t\t\t\t</p>\n\t\t\t\n\t\t\t</div>\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\n\t\t\t\t\$('#deleteMessage').dialog({\n\t\t\t\t\n\t\t\t\t\ttitle: 'Delete Forum Category',\n\t\t\t\t\twidth: 400,\n\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\tresizable: false,\n\t\t\t\t\tmodal: true,\n\t\t\t\t\tshow: 'scale',\n\t\t\t\t\tbuttons: {\n\t\t\t\t\t\n\t\t\t\t\t\t'OK': function() {\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t</script>\n\t\t\n\t\t";
    } elseif (count($arrBoards) == 0 && !isset($_POST['confirm'])) {
        echo "\n\t\t\n\t\t\t<div id='deleteMessage' style='display: none'>\n\t\t\t\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\tAre you sure you want to delete the category, <b>" . $categoryInfo['name'] . "</b>?\n\t\t\t\t</p>\n\t\t\t\n\t\t\t</div>\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\n\t\t\t\t\$('#deleteMessage').dialog({\n\t\t\t\t\n\t\t\t\t\ttitle: 'Delete Forum Category',\n\t\t\t\t\twidth: 400,\n\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\tresizable: false,\n\t\t\t\t\tmodal: true,\n\t\t\t\t\tshow: 'scale',\n\t\t\t\t\tbuttons: {\n\t\t\t\t\t\t\n\t\t\t\t\t\t'Yes': function() {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$('#loadingSpiral').show();\n\t\t\t\t\t\t\t\$('#categoryList').fadeOut(250);\n\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "members/include/forum/include/delete_category.php', { catID: '" . $_POST['catID'] . "', confirm: 1 }, function(data) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\$('#categoryList').html(data);\n\t\t\t\t\t\t\t\t\$('#loadingSpiral').hide();\n\t\t\t\t\t\t\t\t\$('#categoryList').fadeIn(250);\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\t\t\t\t\t\n\t\t\t\t\t\t},\n\t\t\t\t\t\t'Cancel': function() {\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t</script>\n\t\t\n\t\t\n\t\t";
    } elseif (count($arrBoards) == 0 && isset($_POST['confirm'])) {
        $categoryObj->delete();
        $categoryObj->resortOrder();
示例#20
0
 * License: http://www.bluethrust.com/license.php
 *
 */
if (!isset($member) || substr($_SERVER['PHP_SELF'], -11) != "console.php") {
    exit;
} else {
    $memberInfo = $member->get_info();
    $consoleObj->select($_GET['cID']);
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
$cID = $_GET['cID'];
include_once "../classes/btupload.php";
if ($_POST['submit']) {
    $diplomacyStatusObj = new BasicOrder($mysqli, "diplomacy_status", "diplomacystatus_id");
    // Check Name
    if (trim($_POST['statusname']) == "") {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> Status name may not be blank.<br>";
        $countErrors++;
    }
    // Check Display Order
    $intNewOrderNum = $diplomacyStatusObj->validateOrder($_POST['displayorder'], $_POST['beforeafter']);
    if ($intNewOrderNum === false) {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> You selected an invalid display order.<br>";
        $countErrors++;
    }
    $statusImageURL = "";
    if ($countErrors == 0) {
        // If no errors, check for image upload and try to upload the image
        if ($_FILES['statusimagefile']['name'] != "") {
示例#21
0
<?php

/*
 * Bluethrust Clan Scripts v4
 * Copyright 2014
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include "../../../../_setup.php";
include_once "../../../../classes/member.php";
include_once "../../../../classes/rank.php";
include_once "../../../../classes/consoleoption.php";
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$diplomacyStatusObj = new BasicOrder($mysqli, "diplomacy_status", "diplomacystatus_id");
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Manage Diplomacy Statuses");
$consoleObj->select($cID);
if ($member->authorizeLogin($_SESSION['btPassword'])) {
    $memberInfo = $member->get_info_filtered();
    if (($memberInfo['rank_id'] == 1 || $member->hasAccess($consoleObj)) && $diplomacyStatusObj->select($_POST['sID'])) {
        define('MEMBERRANK_ID', $memberInfo['rank_id']);
        $diplomacyStatusObj->move($_POST['sDir']);
        include "main_managestatuses.php";
    }
}
示例#22
0
 */
if (!isset($member) || substr($_SERVER['PHP_SELF'], -11) != "console.php") {
    include_once "../../../../_setup.php";
    include_once "../../../../classes/member.php";
    include_once "../../../../classes/basicorder.php";
    $consoleObj = new ConsoleOption($mysqli);
    $member = new Member($mysqli);
    $member->select($_SESSION['btUsername']);
    $cID = $consoleObj->findConsoleIDByName("Member Application");
    $consoleObj->select($cID);
    if (!$member->authorizeLogin($_SESSION['btPassword']) || !$member->hasAccess($consoleObj)) {
        exit;
    }
}
echo "\n\n\t\t<table class='formTable' style='width: 90%; margin-top: 0px'>\n\t\t\t<tr>\n\t\t\t\t<td class='main' style='width: 50%'>Username</td>\n\t\t\t\t<td class='main' align='center' style='width: 25%'>Input</td>\n\t\t\t\t<td class='main' align='center' style='width: 25%; height: 24px'>N/A</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td class='main' style='width: 50%'>Password</td>\n\t\t\t\t<td class='main' align='center' style='width: 25%'>Input</td>\n\t\t\t\t<td class='main' align='center' style='width: 25%; height: 24px'>N/A</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td class='main' style='width: 50%'>E-mail Address</td>\n\t\t\t\t<td class='main' align='center' style='width: 25%'>Input</td>\n\t\t\t\t<td class='main' align='center' style='width: 25%; height: 24px'>N/A</td>\n\t\t\t</tr>\n\t\t\t";
$objAppComponent = new BasicOrder($mysqli, "app_components", "appcomponent_id");
$result = $mysqli->query("SELECT appcomponent_id FROM " . $dbprefix . "app_components ORDER BY ordernum DESC");
while ($row = $result->fetch_assoc()) {
    $objAppComponent->select($row['appcomponent_id']);
    $appComponentInfo = $objAppComponent->get_info_filtered();
    $dispUpArrow = "<a href='javascript:void(0)' onclick=\"moveAppComponent('up', '" . $row['appcomponent_id'] . "')\"><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/uparrow.png' width='24' height='24' title='Move Up'></a>";
    $dispDownArrow = "<a href='javascript:void(0)' onclick=\"moveAppComponent('down', '" . $row['appcomponent_id'] . "')\"><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/downarrow.png' width='24' height='24' title='Move Down'></a>";
    if ($appComponentInfo['ordernum'] == 1) {
        $dispDownArrow = "<img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/transparent.png' width='24' height='24'>";
    }
    if ($appComponentInfo['ordernum'] == $objAppComponent->getHighestOrderNum()) {
        $dispUpArrow = "<img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/transparent.png' width='24' height='24'>";
    }
    switch ($appComponentInfo['componenttype']) {
        case "multiselect":
            $appComponentInfo['componenttype'] = "Multi-Select";
示例#23
0
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include_once "../../../../_setup.php";
include_once "../../../../classes/member.php";
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$consoleObj = new ConsoleOption($mysqli);
$manageStatusCID = $consoleObj->findConsoleIDByName("Manage Diplomacy Statuses");
$consoleObj->select($manageStatusCID);
$diplomacyStatusObj = new BasicOrder($mysqli, "diplomacy_status", "diplomacystatus_id");
$diplomacyStatusObj->set_assocTableName("diplomacy");
$diplomacyStatusObj->set_assocTableKey("diplomacy_id");
if ($member->authorizeLogin($_SESSION['btPassword']) && $diplomacyStatusObj->select($_POST['sID']) && $member->hasAccess($consoleObj)) {
    $statusName = $diplomacyStatusObj->get_info_filtered("name");
    $arrAssociates = $diplomacyStatusObj->getAssociateIDs();
    if (count($arrAssociates) > 0) {
        echo "\n\t\t\t\n\t\t\t<div id='deleteDialogBox' style='display: none'>\n\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\tThere are currently clans on the diplomacy page with the " . $statusName . " status.  You must change their status before deleting.\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\n\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\n\t\t\t\t\t\$('#deleteDialogBox').dialog({\n\t\t\t\t\t\ttitle: 'Delete Diplomacy Status',\n\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\tshow: 'scale',\n\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\tbuttons: {\n\t\t\t\t\t\t\t'OK': function() {\n\t\t\t\t\t\t\t\t\$(this).dialog('close');\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t},\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t});\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t</script>\n\t\t\t\n\t\t";
    } elseif (count($arrAssociates) == 0 && !isset($_POST['confirmDelete'])) {
        echo "\n\t\t\t\n\t\t\t<div id='deleteDialogBox' style='display: none'>\n\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\tAre you sure you want to delete the <b>" . $statusName . "</b> diplomacy status?\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\n\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\n\t\t\t\t\t\$('#deleteDialogBox').dialog({\n\t\t\t\t\t\ttitle: 'Delete Diplomacy Status',\n\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\tshow: 'scale',\n\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\tbuttons: {\n\t\t\t\t\t\t\t'Yes': function() {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\$('#loadingSpiral').show();\n\t\t\t\t\t\t\t\t\$('#statusListDiv').hide();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "members/include/diplomacy/include/deletestatus.php', { sID: '" . $_POST['sID'] . "', confirmDelete: 1 }, function(data1) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\$('#statusListDiv').html(data1);\n\t\t\t\t\t\t\t\t\t\$('#loadingSpiral').hide();\n\t\t\t\t\t\t\t\t\t\$('#statusListDiv').fadeIn(250);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t'Cancel': function() {\n\t\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t});\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t</script>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t";
    } elseif (count($arrAssociates) == 0 && isset($_POST['confirmDelete'])) {
        $diplomacyStatusObj->set_assocTableName("");
        $diplomacyStatusObj->delete();
        $member->logAction("Deleted the " . $statusName . " diplomacy status.");
        include "main_managestatuses.php";
    }
示例#24
0
}
$cID = $_GET['cID'];
$forumAttachmentsCID = $consoleObj->findConsoleIDByName("Post Forum Attachments");
$consoleObj->select($forumAttachmentsCID);
$blnCheckForumAttachments = $member->hasAccess($consoleObj);
$consoleObj->select($cID);
if ($blnCheckForumAttachments) {
    include_once $prevFolder . "classes/download.php";
    include_once $prevFolder . "classes/downloadcategory.php";
    $attachmentObj = new Download($mysqli);
    $downloadCatObj = new DownloadCategory($mysqli);
    $downloadCatObj->selectBySpecialKey("forumattachments");
    $forumAttachmentCatID = $downloadCatObj->get_info("downloadcategory_id");
}
$boardObj = new ForumBoard($mysqli);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
if (!$boardObj->select($_GET['bID']) || $boardObj->select($_GET['bID']) && !$boardObj->memberHasAccess($memberInfo)) {
    echo "<script type='text/javascript'>window.location = '" . $MAIN_ROOT . "members'</script>";
    exit;
}
$boardInfo = $boardObj->get_info_filtered();
$blnPostReply = false;
$addToForm = "";
if (isset($_GET['tID']) && $boardObj->objTopic->select($_GET['tID'])) {
    $blnPostReply = true;
    $topicInfo = $boardObj->objTopic->get_info();
    // Check if topic is actually in the selected board
    if ($topicInfo['forumboard_id'] != $boardInfo['forumboard_id']) {
        echo "<script type='text/javascript'>window.location = '" . $MAIN_ROOT . "members'</script>";
示例#25
0
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
// Config File
$prevFolder = "../";
include $prevFolder . "_setup.php";
$consoleObj = new ConsoleOption($mysqli);
$boardObj = new ForumBoard($mysqli);
$subForumObj = new ForumBoard($mysqli);
$member = new Member($mysqli);
$postMemberObj = new Member($mysqli);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$categoryObj->set_assocTableName("forum_board");
$categoryObj->set_assocTableKey("forumboard_id");
$ipbanObj = new Basic($mysqli, "ipban", "ipaddress");
if ($ipbanObj->select($IP_ADDRESS, false)) {
    $ipbanInfo = $ipbanObj->get_info();
    if (time() < $ipbanInfo['exptime'] or $ipbanInfo['exptime'] == 0) {
        die("<script type='text/javascript'>window.location = '" . $MAIN_ROOT . "banned.php';</script>");
    } else {
        $ipbanObj->delete();
    }
}
// Start Page
$PAGE_NAME = "Forum - ";
include $prevFolder . "themes/" . $THEME . "/_header.php";
// Check Private Forum
示例#26
0
$diplomacyObj = new Basic($mysqli, "diplomacy", "diplomacy_id");
if (!$diplomacyObj->select($_GET['dID'])) {
    echo "\n\t\t<script type='text/javascript'>\n\t\t\twindow.location = '" . $MAIN_ROOT . "diplomacy'\n\t\t</script>\n\t";
    exit;
}
$ipbanObj = new Basic($mysqli, "ipban", "ipaddress");
if ($ipbanObj->select($IP_ADDRESS, false)) {
    $ipbanInfo = $ipbanObj->get_info();
    if (time() < $ipbanInfo['exptime'] or $ipbanInfo['exptime'] == 0) {
        die("<script type='text/javascript'>window.location = '" . $MAIN_ROOT . "banned.php';</script>");
    } else {
        $ipbanObj->delete();
    }
}
$diplomacyInfo = $diplomacyObj->get_info_filtered();
$diplomacyStatusObj = new BasicOrder($mysqli, "diplomacy_status", "diplomacystatus_id");
$diplomacyStatusObj->select($diplomacyInfo['diplomacystatus_id']);
$statusInfo = $diplomacyStatusObj->get_info_filtered();
if ($statusInfo['imageurl'] == "") {
    $dispStatus = $statusInfo['name'];
} else {
    if (strpos($statusInfo['imageurl'], "http://") === false) {
        $statusInfo['imageurl'] = "../" . $statusInfo['imageurl'];
    }
    $dispImgWidth = "";
    $dispImgHeight = "";
    if ($statusInfo['imagewidth'] != 0) {
        $dispImgWidth = " width = '" . $statusInfo['imagewidth'] . "' ";
    }
    if ($statusInfo['imageheight'] != 0) {
        $dispImgWidth = " height = '" . $statusInfo['imageheight'] . "' ";
示例#27
0
    $memberInfo = $member->get_info();
    $consoleObj->select($_GET['cID']);
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
$cID = $_GET['cID'];
$dispError = "";
$countErrors = 0;
$result = $mysqli->query("SELECT * FROM " . $dbprefix . "forum_category ORDER BY ordernum DESC");
if ($result->num_rows == 0) {
    echo "\n\t\n\t\t<div style='display: none' id='successBox'>\n\t\t\t\t<p align='center'>\n\t\t\t\t\tYou must add a forum category before adding a board!\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\tpopupDialog('Add Board', '" . $MAIN_ROOT . "members/index.php?select=" . $consoleInfo['consolecategory_id'] . "', 'successBox');\n\t\t\t</script>\n\t\n\t";
    exit;
}
$boardObj = new ForumBoard($mysqli);
$categoryObj = new BasicOrder($mysqli, "forum_category", "forumcategory_id");
$rankCatObj = new RankCategory($mysqli);
$rankObj = new Rank($mysqli);
$tempMemObj = new Member($mysqli);
if ($_POST['submit']) {
    // Check Board Name
    if (trim($_POST['boardname']) == "") {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> Board name may not be blank.<br>";
        $countErrors++;
    }
    // Check Category
    if (!$categoryObj->select($_POST['forumcat'])) {
        $dispError .= "&nbsp;&nbsp;&nbsp;<b>&middot;</b> You selected an invalid forum category.<br>";
        $countErrors++;
    }
    // Check Subforum