Example #1
0
 public function displayForumActivity($amountToShow = 5)
 {
     $forumObj = new ForumBoard($this->MySQL);
     $arrForumActivity = $this->getForumActivity($amountToShow);
     $member = new Member($this->MySQL);
     if (file_exists(BASE_DIRECTORY . "themes/" . $this->dir . "/menus/forumactivity.php")) {
         if (!defined("FORUMACTIVITY_MENUITEM")) {
             define("FORUMACTIVITY_MENUITEM", true);
         }
         include BASE_DIRECTORY . "themes/" . $this->dir . "/menus/forumactivity.php";
     } else {
         echo "\n\t\t\t\t\t<div class='menusForumActivityWrapper'>\n\t\t\t\t";
         $altColorSwitch = 0;
         foreach ($arrForumActivity as $forumPostID) {
             $forumObj->objPost->select($forumPostID);
             $postInfo = $forumObj->objPost->get_info_filtered();
             $forumObj->objTopic->select($postInfo['forumtopic_id']);
             $topicInfo = $forumObj->objTopic->get_info_filtered();
             $topicPostInfo = $forumObj->objPost->getTopicInfo(true);
             $member->select($postInfo['member_id']);
             if ($altColorSwitch == 1) {
                 $addCSS = "";
                 $altColorSwitch = 0;
             } else {
                 $addCSS = " alternateBGColor";
                 $altColorSwitch = 1;
             }
             echo "\n\t\t\t\t\t\t<div class='menusForumActivityItemWrapper dottedLine " . $addCSS . "'>\n\t\t\t\t\t\t\t<div class='menusForumActivityAvatarDiv'>\n\t\t\t\t\t\t\t\t" . $member->getAvatar() . "\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class='menusForumActivityTextWrapper'>\n\t\t\t\t\t\t\t\t<div class='menusForumActivityPostTitle'>\n\t\t\t\t\t\t\t\t\t<a href='" . $forumObj->objPost->getLink() . "' title='" . $topicPostInfo['title'] . "'>" . $topicPostInfo['title'] . "</a>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class='menusForumActivityPoster'>\n\t\t\t\t\t\t\t\t\tby " . $member->getMemberLink() . "\n\t\t\t\t\t\t\t\t</div><span class='menusForumActivityDate'>" . getPreciseTime($postInfo['dateposted']) . "</span>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div style='clear: both'></div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t";
         }
         echo "\n\t\t\t\t\t</div>\n\t\t\t\t";
     }
 }
Example #2
0
 public function dispShoutbox($setWidth = 0, $setHeight = 0, $blnPercentWidth = false, $txtBoxWidth = 0, $blnPercentHeight = false)
 {
     global $MAIN_ROOT, $THEME;
     if ($setWidth > 0) {
         $this->intDispWidth = $setWidth;
     }
     if ($setHeight > 0) {
         $this->intDispHeight = $setHeight;
     }
     $dispWidthPX = "px";
     if ($blnPercentWidth) {
         $dispWidthPX = "%";
     }
     $dispHeightPX = "px";
     if ($blnPercentHeight) {
         $dispHeightPX = "%";
     }
     $result = $this->MySQL->query("SELECT * FROM " . $this->strTableName . " WHERE newstype = '3'" . $this->strSQLSort . " ORDER BY dateposted");
     while ($row = $result->fetch_assoc()) {
         if ($this->memberObj->select($row['member_id'])) {
             $memberLink = $this->memberObj->getMemberLink();
             $dispPost = nl2br(parseBBCode(wordwrap(filterText($row['newspost']), $this->intWordWrap)));
             $dispTime = "<p align='center' style='font-size: 9px'><br>" . getPreciseTime($row['dateposted']) . "</p>";
             $dispManagePost = "";
             if ($this->strEditLink != "" && $this->strDeleteLink != "") {
                 $dispManagePost = "<p align='center'><span class='loadingSpiral' id='" . $this->strDivID . "_loading_" . $row[$this->strTableKey] . "'><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/loading-spiral2.gif' width='30' height='30'></span><span class='tinyFont' id='" . $this->strDivID . "_manage_" . $row[$this->strTableKey] . "'><br><b><a href='" . $this->strEditLink . $row[$this->strTableKey] . "'>EDIT</a> - <a href='javascript:void(0)' onclick=\"deleteShoutbox('" . $row[$this->strTableKey] . "', '" . $this->strDeleteLink . "', '" . $this->strDivID . "')\">DELETE</a></b></span></p>";
             }
             $shoutBoxInfo .= "\n\t\t\t\t\t<b>" . $memberLink . ":</b><br>\n\t\t\t\t\t<div style='word-wrap: break-word;'>" . $dispPost . "</div>\n\t\t\t\t\t" . $dispTime . "\n\t\t\t\t\t" . $dispManagePost . "\n\t\t\t\t\t<div class='dottedLine' style='margin: 5px 0px'></div>\n\t\t\t\t";
         }
     }
     $addToReturn = "";
     $addToReturn2 = "";
     $setMainShoutbox = "";
     if ($this->blnMainShoutbox) {
         $setMainShoutbox = " data-shoutbox='main' ";
     }
     if (!$this->blnUpdateShoutbox) {
         $addToReturn = "<div class='shoutBox' id='" . $this->strDivID . "'" . $setMainShoutbox . " style='width: " . $this->intDispWidth . $dispWidthPX . "; height: " . $this->intDispHeight . $dispHeightPX . "'>";
         $addToReturn2 = "</div>";
     }
     $returnVal = $addToReturn . $shoutBoxInfo . $addToReturn2;
     if ($this->strPostLink != "") {
         $setTxtBoxWidth = $this->intDispWidth - 10;
         if ($txtBoxWidth > 0) {
             $setTxtBoxWidth = $txtBoxWidth;
         }
         $returnVal .= "\n\t\t\t<div class='shoutBoxPost' style='text-align: center; width: 100%' id='" . $this->strDivID . "_postShoutbox'>\n\t\t\t\t<div style='margin-left: auto; margin-right: auto; width: " . $setTxtBoxWidth . $dispWidthPX . "'>\n\t\t\t\t\t<textarea class='textBox' rows='1' style='margin-left: auto; margin-right: auto; width: 100%; height: 25px' id='" . $this->strDivID . "_message'></textarea>\n\t\t\t\t\t<p align='right' style='margin-right: -3px; padding-top: 1px; margin-top: 3px'><input type='button' class='submitButton' value='POST' onclick=\"postShoutbox('" . $this->strDivID . "', '" . $this->strPostLink . "')\" style='padding: 5px'></p>\n\t\t\t\t</div>\n\t\t\t</div>";
     }
     return $returnVal;
 }
Example #3
0
function post_topic_redirect()
{
    global $mysqli, $boardObj, $postInfo, $MAIN_ROOT, $topicInfo, $member;
    if ($_POST['postredirect'] == 1) {
        $boardObj->select($_POST['moveto']);
        $arrColumns = array("forumboard_id", "lockstatus");
        $arrValues = array($topicInfo['forumboard_id'], 1);
        $boardObj->objTopic->addNew($arrColumns, $arrValues);
        $message = str_replace("[BOARD]", "<a href='" . $MAIN_ROOT . "forum/viewboard.php?bID=" . $_POST['moveto'] . "'>" . $boardObj->get_info_filtered("name") . "</a>", $_POST['postredirect_desc']);
        $message = str_replace("[TOPIC_LINK]", "<a href='" . $MAIN_ROOT . "forum/viewtopic.php?tID=" . $_GET['topicID'] . "'>" . $postInfo['title'] . "</a>", $message);
        $message .= "\n\n\n<p class='tinyFont'><i>Moved by " . $member->getMemberLink() . " on " . getPreciseTime(time(), "", true) . "</i></p>";
        $arrColumns = array("member_id", "dateposted", "title", "message", "forumtopic_id");
        $arrValues = array($postInfo['member_id'], time(), "MOVED - " . $postInfo['title'], $message, $boardObj->objTopic->get_info("forumtopic_id"));
        $boardObj->objPost->addNew($arrColumns, $arrValues);
        $boardObj->objTopic->update(array("forumpost_id", "lastpost_id"), array($boardObj->objPost->get_info("forumpost_id"), $boardObj->objPost->get_info("forumpost_id")));
    }
    $member->logAction("Moved forum topic, <a href='" . $MAIN_ROOT . "forum/viewtopic.php?tID=" . $topicInfo['forumtopic_id'] . "'>" . $postInfo['title'] . "</a>, to <a href='" . $MAIN_ROOT . "forum/viewboard.php?bID=" . $_POST['moveto'] . "'>" . $boardObj->get_info_filtered("name") . "</a>");
}
function dispIAMessages($iaID)
{
    global $MAIN_ROOT, $dbprefix, $mysqli;
    $iaMember = new Member($mysqli);
    $counter = 0;
    $iaMessages = "";
    $iaMessagesQuery = $mysqli->query("SELECT * FROM " . $dbprefix . "iarequest_messages WHERE iarequest_id = '" . $iaID . "' ORDER BY messagedate DESC");
    while ($iaMessageRow = $iaMessagesQuery->fetch_assoc()) {
        if ($counter == 1) {
            $addCSS = "";
            $counter = 0;
        } else {
            $addCSS = " alternateBGColor";
            $counter = 1;
        }
        $iaMember->select($iaMessageRow['member_id']);
        $iaMessages .= "\n\t\t\t<div class='dottedLine" . $addCSS . "' style='padding: 10px 5px; margin-left: auto; margin-right: auto; width: 80%;'>\n\t\t\t\t" . $iaMember->getMemberLink() . " - " . getPreciseTime($iaMessageRow['messagedate']) . "<br><br>\n\t\t\t\t<div style='padding-left: 5px'>" . nl2br(filterText($iaMessageRow['message'])) . "</div>\n\t\t\t</div>\n\t\t";
    }
    if ($iaMessagesQuery->num_rows == 0) {
        $iaMessages = "<i>No Messages</i>";
    }
    return $iaMessages;
}
 *
 * Author: Bluethrust Web Development
 * E-mail: support@bluethrust.com
 * Website: http://www.bluethrust.com
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
if (!defined("SHOW_SHOUTBOXLIST")) {
    exit;
}
echo "\n\t<table class='formTable'  style='margin-top: 0px; border-spacing: 0px; table-layout: fixed'>\n\t";
$counter = 0;
$manageNewsCID = $consoleObj->findConsoleIDByName("Manage News");
$result = $mysqli->query("SELECT * FROM " . $dbprefix . "news WHERE newstype = '3' ORDER BY dateposted DESC");
while ($row = $result->fetch_assoc()) {
    $dispPoster = $member->select($row['member_id']) ? $member->getMemberLink() : "Unknown";
    if ($counter == 0) {
        $addCSS = "";
        $counter = 1;
    } else {
        $addCSS = " alternateBGColor";
        $counter = 0;
    }
    echo "\n\t\t<tr>\n\t\t\t<td class='pmInbox main solidLine" . $addCSS . "' style='padding-left: 0px' width=\"5%\"><input type='checkbox' value='" . $row['news_id'] . "' class='textBox'></td>\n\t\t\t<td class='pmInbox main solidLine" . $addCSS . "' style='padding-left: 5px' width=\"30%\">" . $dispPoster . "</a></div></td>\n\t\t\t<td class='pmInbox main solidLine" . $addCSS . "' style='padding-left: 5px; overflow: hidden' width=\"35%\"><div style='width: 85%; white-space:nowrap; overflow: hidden; text-overflow: ellipsis'><a href='" . $MAIN_ROOT . "members/console.php?cID=" . $manageNewsCID . "&newsID=" . $row['news_id'] . "'>" . filterText($row['newspost']) . "</a></div></td>\n\t\t\t<td class='pmInbox main solidLine" . $addCSS . "' style='padding-left: 5px' width=\"30%\">" . getPreciseTime($row['dateposted']) . "</td>\n\t\t</tr>\n\t";
}
if ($result->num_rows == 0) {
    echo "\t\n\t\t<tr>\n\t\t\t<td class='main' align='center' colspan='4'>\n\t\t\t\t<div class='shadedBox' style='margin-top: 20px; width: 45%; margin-left: auto; margin-right: auto'>\n\t\t\t\t\t<p align='center'><i>There are no shoutbox posts!</i></p>\n\t\t\t\t</div>\n\t\t\t</td>\n\t\t</tr>\n\t";
}
echo "</table>";
$member->select($memberInfo['member_id']);
Example #6
0
    } else {
        echo "\n\t\t\t\n\t\t\t<div class='shadedBox' style='margin-left: auto; margin-right: auto; width: 50%'>\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\tUnable to connect account!  Please Try Again.<br><br>\n\t\t\t\t\t<a href='" . $MAIN_ROOT . "members/console.php?cID=" . $_GET['cID'] . "'>Retry</a>\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\n\t\t";
    }
} elseif ($twitterObj->hasTwitter($memberInfo['member_id'])) {
    $dispSuccess = false;
    if ($_POST['submit']) {
        $setShowFeed = $_POST['showfeed'] == 1 ? 1 : 0;
        $setEmbedTweet = $_POST['embedlasttweet'] == 1 ? 1 : 0;
        $setInfoCard = $_POST['showinfo'] == 1 ? 1 : 0;
        $setAllowLogin = $_POST['allowlogin'] == 1 ? 1 : 0;
        $arrColumns = array("showfeed", "embedtweet", "infocard", "allowlogin");
        $arrValues = array($setShowFeed, $setEmbedTweet, $setInfoCard, $setAllowLogin);
        $twitterObj->update($arrColumns, $arrValues);
        $dispSuccess = true;
    }
    // MEMBER ALREADY HAS TWITTER CONNECTED
    $twitterObj->oauthToken = $twitterObj->get_info("oauth_token");
    $twitterObj->oauthTokenSecret = $twitterObj->get_info("oauth_tokensecret");
    $twitterObj->reloadCacheInfo();
    $twitterInfo = $twitterObj->get_info_filtered();
    $checkShowFeed = $twitterInfo['showfeed'] == 1 ? " checked" : "";
    $checkEmbedTweet = $twitterInfo['embedtweet'] == 1 ? " checked" : "";
    $checkInfoCard = $twitterInfo['infocard'] == 1 ? " checked" : "";
    $checkAllowLogin = $twitterInfo['allowlogin'] == 1 ? " checked" : "";
    echo "\n\t\n\t\t<div id='connectedDiv'>\n\t\t\t<form action='" . $MAIN_ROOT . "members/console.php?cID=" . $_GET['cID'] . "' method='post'>\n\t\t\t\t<div class='formDiv'>\n\t\t\t\t\t<table class='formTable'>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td colspan='2'>\n\t\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 20px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t\t<b>Connected:</b>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td colspan='2'>\n\t\t\t\t\n\t\t\t\t\t\t\t\t<div class='shadedBox' style='margin-left: auto; margin-right: auto; width: 50%; overflow: auto'>\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t" . $twitterObj->dispCard() . "\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div style='font-style: italic; text-align: center; margin-top: 3px; margin-left: auto; margin-right: auto; position: relative' class='main'>\n\t\t\t\t\t\t\t\t\tLast updated " . getPreciseTime($twitterInfo['lastupdate']) . "\n\t\t\t\t\t\t\t\t\t<p class='largeFont' style='font-style: normal; font-weight: bold' align='center'>\n\t\t\t\t\t\t\t\t\t\t<a style='cursor: pointer' id='btnDisconnect'>DISCONNECT ACCOUNT</a>\n\t\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td colspan='2'><br><br>\n\t\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 2px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t\t<b>Profile Display Options:</b>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div style='padding-left: 3px; margin-bottom: 15px'>\n\t\t\t\t\t\t\t\t\tUse the form below to set which items from Twitter will show in your profile.\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='formLabel'>Show Feed:</td>\n\t\t\t\t\t\t\t<td class='main'><input type='checkbox' name='showfeed' value='1'" . $checkShowFeed . "></td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='formLabel'>Embed Last Tweet:</td>\n\t\t\t\t\t\t\t<td class='main'><input type='checkbox' name='embedlasttweet' value='1'" . $checkEmbedTweet . "></td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='formLabel'>Show Info Card: <a href='javascript:void(0)' onmouseover=\"showToolTip('An example of the Info Card is shown in the &quot;Connected&quot; section above.')\" onmouseout='hideToolTip()'>(?)</a></td>\n\t\t\t\t\t\t\t<td class='main'><input type='checkbox' name='showinfo' value='1'" . $checkInfoCard . "></td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td colspan='2'><br>\n\t\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 2px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t\t<b>Log In Options:</b>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div style='padding-left: 3px; margin-bottom: 15px'>\n\t\t\t\t\t\t\t\t\tCheck the box below to allow logging into this website through Twitter.\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='formLabel'>Allow Log In:</td>\n\t\t\t\t\t\t\t<td class='main'><input type='checkbox' name='allowlogin' value='1'" . $checkAllowLogin . "></td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='main' colspan='2' align='center'><br>\n\t\t\t\t\t\t\t\t<input type='submit' name='submit' value='Save' class='submitButton'>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t</table>\n\t\t\t\t\t<br>\n\t\t\t\t</div>\n\t\t\t</form>\n\t\t</div>\n\t\t\n\t\t<div id='disconnectDiv' style='display: none'>\n\t\t\t<p class='main' align='center'>\n\t\t\t\tAre you sure you want to disconnect your Twitter account?\n\t\t\t</p>\n\t\t</div>\n\t\t\n\t\t<script type='text/javascript'>\n\t\t\n\t\t\t\$(document).ready(function() {\n\t\t\t\n\t\t\t\t\$('#btnDisconnect').click(function() {\n\t\t\t\t\t\n\t\t\t\t\t\$('#disconnectDiv').dialog({\n\t\t\t\t\t\ttitle: 'Disconnect Twitter',\n\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\tshow: 'scale',\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\$('#connectedDiv').fadeOut(250);\n\t\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "plugins/twitter/disconnect.php', { }, function(data) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\$('#connectedDiv').html(data);\n\t\t\t\t\t\t\t\t\t\$('#connectedDiv').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\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'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\t\$('.ui-dialog :button').blur();\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t});\n\t\t\n\t\t</script>\n\t";
    if ($dispSuccess) {
        echo "\n\t\t\t<div id='successDiv' style='display: none'>\n\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\tTwitter Connect Settings Saved!\n\t\t\t\t</p>\n\t\t\t</div>\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\$('#successDiv').dialog({\n\t\t\t\t\t\ttitle: 'Twitter Connect',\n\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\tshow: 'scale',\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');\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\t\$('.ui-dialog :button').blur();\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";
    }
} else {
    echo "\n\t\n\t\t<script type='text/javascript'>\n\t\t\t\n\t\t\twindow.location = '" . $MAIN_ROOT . "members';\n\t\t\n\t\t</script>\n\t\n\t";
}
Example #7
0
        }
    }
    $ytInfo = $ytObj->get_info_filtered();
    $checkVideos = array();
    if ($ytInfo['showvideos'] == 0) {
        $checkVideos[0] = " selected";
    } elseif ($ytInfo['showvideos'] == 1) {
        $checkVideos[1] = " selected";
    }
    $checkInfoCard = $ytInfo['showsubscribe'] == 1 ? " checked" : "";
    $checkAllowLogin = $ytInfo['allowlogin'] == 1 ? " checked" : "";
    echo "\n\t\t\t<div id='loadingSpiralDisconnect' class='loadingSpiral'>\n\t\t\t\t<p align='center'>\n\t\t\t\t\t<img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/loading-spiral.gif'><br>Loading\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\t<div id='connectedDiv'>\n\t\t\t<form action='" . $MAIN_ROOT . "members/console.php?cID=" . $_GET['cID'] . "' method='post'>\n\t\t\t<div class='formDiv'>\n\t\t\t";
    if ($dispError != "") {
        echo "\n\t\t\t<div class='errorDiv'>\n\t\t\t<strong>Unable to save Youtube settings because the following errors occurred:</strong><br><br>\n\t\t\t{$dispError}\n\t\t\t</div>\n\t\t\t";
    }
    echo "\n\t\t\t\n\t\t\t\t<table class='formTable'>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td colspan='2'>\n\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 20px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t<b>Connected:</b>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td colspan='2'>\n\t\t\t\t\t\t\t<div id='loadingSpiral' class='loadingSpiral' style='padding-top: 0px'>\n\t\t\t\t\t\t\t\t<p align='center'>\n\t\t\t\t\t\t\t\t\t<img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/loading-spiral.gif'><br>Refreshing Data\n\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div id='ytInfoCard'>" . $ytObj->dispSubscribeButton() . "</div>\n\t\t\t\t\t\t\t<div style='font-style: italic; text-align: center; margin-top: 3px; margin-left: auto; margin-right: auto; position: relative' class='main'>\n\t\t\t\t\t\t\t\tLast updated <span id='lastUpdateTime'>" . getPreciseTime($ytInfo['lastupdate']) . "</span>\n\t\t\t\t\t\t\t\t<p class='largeFont' style='font-style: normal; font-weight: bold' align='center'>\n\t\t\t\t\t\t\t\t\t<a style='cursor: pointer' id='btnDisconnect'>DISCONNECT ACCOUNT</a>\n\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td colspan='2'>\n\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 20px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t<b>Profile Display Options:</b>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td class='formLabel'>Show Info Card: <a href='javascript:void(0)' onmouseover=\"showToolTip('An example of the Info Card is shown in the &quot;Connected&quot; section above.')\" onmouseout='hideToolTip()'>(?)</a></td>\n\t\t\t\t\t\t<td class='main'><input type='checkbox' name='showinfocard' value='1'" . $checkInfoCard . "></td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td class='formLabel'>Video Display:</td>\n\t\t\t\t\t\t<td class='main'>\n\t\t\t\t\t\t\t<select name='showvideos' class='textBox'>\n\t\t\t\t\t\t\t\t<option value='0'" . $checkVideos[0] . ">Don't Show Videos</option>\n\t\t\t\t\t\t\t\t<option value='1'" . $checkVideos[1] . ">Most Recent Video</option>\n\t\t\t\t\t\t\t\t";
    for ($i = 2; $i <= 5; $i++) {
        $dispChecked = "";
        if ($ytInfo['showvideos'] == $i) {
            $dispChecked = " selected";
        }
        echo "<option value='" . $i . "'" . $dispChecked . ">" . $i . " Most Recent Videos</option>";
    }
    echo "\n\t\t\t\t\t\t\t</select>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td colspan='2'><br>\n\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 2px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t<b>Log In Options:</b>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div style='padding-left: 3px; margin-bottom: 15px'>\n\t\t\t\t\t\t\t\tCheck the box below to allow logging into this website through Youtube.\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td class='formLabel'>Allow Log In:</td>\n\t\t\t\t\t\t<td class='main'><input type='checkbox' name='allowlogin' value='1'" . $checkAllowLogin . "></td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td class='main' colspan='2' align='center'><br>\n\t\t\t\t\t\t\t<input type='submit' name='submit' value='Save' class='submitButton'>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t</table>\n\t\t\t\n\t\t\t</div>\n\t\t\t</form>\n\t\t\t</div>\n\t\t\t\n\t\t\t<div id='disconnectDiv' style='display: none'>\n\t\t\t<p class='main' align='center'>\n\t\t\t\tAre you sure you want to disconnect your Youtube account?\n\t\t\t</p>\n\t\t</div>\n\t\t\n\t\t<script type='text/javascript'>\n\t\t\n\t\t\t\$(document).ready(function() {\n\t\t\t\n\t\t\t\t\$('#btnDisconnect').click(function() {\n\t\t\t\t\t\n\t\t\t\t\t\$('#disconnectDiv').dialog({\n\t\t\t\t\t\ttitle: 'Disconnect Youtube',\n\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\tshow: 'scale',\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\$('#connectedDiv').fadeOut(250);\n\t\t\t\t\t\t\t\t\$('#loadingSpiralDisconnect').show();\n\t\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "plugins/youtube/disconnect.php', { }, function(data) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\$('#connectedDiv').html(data);\n\t\t\t\t\t\t\t\t\t\$('#loadingSpiralDisconnect').hide();\n\t\t\t\t\t\t\t\t\t\$('#connectedDiv').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\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'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\t\$('.ui-dialog :button').blur();\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t});\n\t\t\n\t\t</script>\n\t\t\t\n\t\t";
    if (time() - $ytInfo['lastupdate'] > 1800) {
        echo "\n\t\t\t\t\n\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\n\t\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\n\t\t\t\t\t\t\$('#loadingSpiral').show();\n\t\t\t\t\t\t\$('#ytInfoCard').fadeOut(250);\n\t\t\t\t\t\n\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "plugins/youtube/reloadcache.php', { yID: '" . $ytInfo['youtube_id'] . "' }, function(data) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tpostResult = JSON.parse(data);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(postResult['result'] == 'success') {\n\t\t\t\t\t\t\t\t\$('#ytInfoCard').html(postResult['html']);\n\t\t\t\t\t\t\t\t\$('#lastUpdateTime').html(postResult['time']);\n\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$('#ytInfoCard').fadeIn(250);\n\t\t\t\t\t\t\t\$('#loadingSpiral').hide();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tvar bubbleRight = (\$('.ytBubble').width()*-1)-20;\n\t\t\t\t\t\t\t\$('.ytBubble').css('right', bubbleRight+'px');\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});\n\t\t\t\t\n\t\t\t\t</script>\n\t\t\t\n\t\t\t";
    }
    if ($dispSuccess) {
        echo "\n\t\t\t\t<div id='successDiv' style='display: none'>\n\t\t\t\t\t<p align='center' class='main'>\n\t\t\t\t\t\tYoutube Connect Settings Saved!\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\n\t\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\n\t\t\t\t\t\t\$('#successDiv').dialog({\n\t\t\t\t\t\t\ttitle: 'Twitter Connect',\n\t\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\t\tshow: 'scale',\n\t\t\t\t\t\t\tbuttons: {\n\t\t\t\t\t\t\t\t'Ok': function() {\n\t\t\t\t\t\t\t\t\t\$(this).dialog('close');\n\t\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});\n\t\t\t\t\t\t\$('.ui-dialog :button').blur();\n\t\t\t\t\t\n\t\t\t\t\t});\n\t\t\t\t\n\t\t\t\t</script>\n\t\t\t";
    }
}
Example #8
0
    if (time() - $fbInfo['lastupdate'] > 1800) {
        $fbObj->accessToken = $fbInfo['access_token'];
        $fbInfo = $fbObj->getFBInfo();
        if ($fbInfo == "") {
            // User revoked access through Facebook, refresh page and re-ask for access
            $fbObj->delete();
            echo "\n\t\t\t\n\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\n\t\t\t\t\twindow.location = '" . $MAIN_ROOT . "members/console.php?cID=" . $_GET['cID'] . "';\n\t\t\t\t\n\t\t\t\t</script>\n\t\t\t\n\t\t\t";
            exit;
        }
        $arrColumns = array("name", "lastupdate");
        $arrValues = array($fbInfo['name'], time());
        $fbObj->select($fbID);
        $fbObj->update($arrColumns, $arrValues);
        $fbInfo = $fbObj->get_info_filtered();
    }
    echo "\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<div id='connectedDiv'>\n\t\t\t<div class='formDiv'>\n\t\t\t\t<table class='formTable'>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t<div class='main dottedLine' style='margin-bottom: 20px; padding-bottom: 3px'>\n\t\t\t\t\t\t\t\t<b>Connected:</b>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t<div class='shadedBox' style='margin-left: auto; margin-right: auto; width: 50%; overflow: auto'>\n\t\n\t\t\t\t\t\t\t\t<div style='float: left; margin: 3px; padding: 0px' class='solidBox'><img src='" . $fbObj->getProfilePic("normal") . "'></div>\n\t\t\t\t\t\t\t\t<div style='float: left; padding-left: 8px; padding-top: 30px'>\n\t\t\t\t\t\t\t\t\t<span class='breadCrumbTitle' style='padding: 0px'><a href='https://www.facebook.com/profile.php?id=" . $fbInfo['facebook_id'] . "'>" . $fbInfo['name'] . "</a></span>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div style='font-style: italic; text-align: center; margin-top: 3px; margin-left: auto; margin-right: auto; position: relative' class='main'>\n\t\t\t\t\t\t\t\tLast updated " . getPreciseTime($fbInfo['lastupdate']) . "\n\t\t\t\t\t\t\t\t<p class='largeFont' style='font-style: normal; font-weight: bold' align='center'>\n\t\t\t\t\t\t\t\t\t<a style='cursor: pointer' id='btnDisconnect'>DISCONNECT ACCOUNT</a>\n\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\n\t\t\t\t\t\t</td>\n\t\t\t\t\t</tr>\n\t\t\t\t</table>\t\t\n\t\t\t</div>\n\t\t</div>\n\t\t<div id='disconnectDiv' style='display: none'>\n\t\t\t<p class='main' align='center'>\n\t\t\t\tAre you sure you want to disconnect your Facebook account?\n\t\t\t</p>\n\t\t</div>\n\t\t\n\t\t<script type='text/javascript'>\n\t\t\n\t\t\t\$(document).ready(function() {\n\t\t\t\n\t\t\t\t\$('#btnDisconnect').click(function() {\n\t\t\t\t\t\n\t\t\t\t\t\$('#disconnectDiv').dialog({\n\t\t\t\t\t\ttitle: 'Disconnect Facebook',\n\t\t\t\t\t\tmodal: true,\n\t\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\t\twidth: 400,\n\t\t\t\t\t\tresizable: false,\n\t\t\t\t\t\tshow: 'scale',\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\$('#connectedDiv').fadeOut(250);\n\t\t\t\t\t\t\t\t\$('#loadingSpiral').show();\n\t\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "plugins/facebook/disconnect.php', { }, function(data) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\$('#connectedDiv').html(data);\n\t\t\t\t\t\t\t\t\t\$('#loadingSpiral').hide();\n\t\t\t\t\t\t\t\t\t\$('#connectedDiv').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\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'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\t\$('.ui-dialog :button').blur();\n\t\t\t\t\n\t\t\t\t});\n\t\t\t\n\t\t\t});\n\t\t\n\t\t</script>\n\t\n\t";
} elseif (!$blnCheckForFacebook && isset($_GET['code'])) {
    $fbObj->tokenNonce = $_SESSION['btFacebookNonce'];
    $arrURLInfo = parse_url($dispHTTP . $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI']);
    $arrAccessToken = $fbObj->getAccessToken($_GET['code'], $_GET['state'], $arrURLInfo['scheme'] . "://" . $arrURLInfo['host'] . $arrURLInfo['path'] . "?cID=" . $_GET['cID']);
    $_SESSION['btFBAccessToken'] = $arrAccessToken['access_token'];
    if ($fbObj->checkAccessToken()) {
        $fbInfo = $fbObj->getFBInfo();
        // Save in DB
        $arrColumns = array("facebook_id", "member_id", "name", "access_token", "lastupdate");
        $arrValues = array($fbInfo['id'], $memberInfo['member_id'], $fbInfo['name'], $arrAccessToken['access_token'], time());
        $fbObj->addNew($arrColumns, $arrValues);
        echo "\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\twindow.location = '" . $MAIN_ROOT . "members/console.php?cID=" . $_GET['cID'] . "';\n\t\t\t</script>\n\t\t\n\t\t";
    } else {
        echo "\n\t\t\n\t\t\t<div class='shadedBox' style='margin-left: auto; margin-right: auto; width: 50%'>\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\tUnable to connect account!  Please Try Again.<br><br>\n\t\t\t\t\t<a href='" . $MAIN_ROOT . "members/console.php?cID=" . $_GET['cID'] . "'>Retry</a>\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\n\t\t";
    }
Example #9
0
    }
    $pageoptions .= "<option value='" . $i . "'" . $dispSelected . ">" . $i . "</option>";
}
if ($_GET['page'] == 1) {
    $startLimit = 0;
} else {
    $startLimit = ($_GET['page'] - 1) * $_GET['show'];
}
$dispLinks = "";
if ($_GET['page'] == 1 && $numOfPages > 1) {
    $dispLinks = "<a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&page=" . ($_GET['page'] + 1) . "&show=" . $_GET['show'] . "'>Next</a> &raquo;";
} elseif ($_GET['page'] != 1 && $numOfPages > $_GET['page']) {
    $dispLinks = "&laquo; <a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&page=" . ($_GET['page'] - 1) . "&show=" . $_GET['show'] . "'>Previous</a> | <a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&page=" . ($_GET['page'] + 1) . "&show=" . $_GET['show'] . "'>Next</a> &raquo;";
} elseif ($_GET['page'] != 1 && $numOfPages == $_GET['page']) {
    $dispLinks = "&laquo; <a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&page=" . ($_GET['page'] - 1) . "&show=" . $_GET['show'] . "'>Previous</a>";
}
foreach ($arrShowPerPage as $numShowPerPage) {
    $dispSelected = "";
    if ($numShowPerPage == $_GET['show']) {
        $dispSelected = " selected";
    }
    $showoptions .= "<option value='" . $numShowPerPage . "'" . $dispSelected . ">" . $numShowPerPage . " entries per page</option>";
}
echo "\n\t<div class='formDiv'>\n\t\n\t\t<div style='float: left'>\n\t\t\t<p class='main' style='padding-left: 10px'>\n\t\t\t\tDisplay: <select id='showselect' class='textBox'>" . $showoptions . "</select> <input type='button' id='showselectButton' class='submitButton' value='GO'>\n\t\t\t</p>\n\t\t</div>\n\t\t<div style='float: right'>\n\t\t\t<p class='main' align='right' style='padding-right: 10px'>\n\t\t\t\t<b>Page:</b> <select id='pageselect' class='textBox'>" . $pageoptions . "</select> <input type='button' id='pageselectButton' class='submitButton' value='GO'> &nbsp;&nbsp;&nbsp; " . $dispLinks . " \n\t\t\t</p>\n\t\t</div>\n\t\t\n\t\t<table class='formTable'>\n";
$result = $mysqli->query("SELECT * FROM " . $dbprefix . "logs ORDER BY logdate DESC LIMIT " . $startLimit . "," . $_GET['show']);
while ($row = $result->fetch_assoc()) {
    $member->select($row['member_id']);
    $formatDate = getPreciseTime($row['logdate']);
    echo "\n\t\t<tr>\n\t\t\t<td class='formLabel'>Log ID#:</td>\n\t\t\t<td class='main'>" . $row['log_id'] . "</td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='formLabel'>Log Date:</td>\n\t\t\t<td class='main'>" . $formatDate . "</td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='formLabel'>Member:</td>\n\t\t\t<td class='main'>" . $member->getMemberLink() . "</td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='formLabel' valign='top'>Action:</td>\n\t\t\t<td class='main' valign='top'>" . $row['message'] . "</td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td colspan='2' align='center'><br><div class='dottedLine' style='width: 90%'></div><br></td>\n\t\t</tr>\n\t";
}
echo "</table>\n\n<p align='right' style='padding-right: 10px' class='main'>\n\t<a href='javascript:void(0)' id='goUpLink'>^^ Go Up</a>\n</p>\n<div style='clear: both'></div>\n</div>\n\n\n<script type='text/javascript'>\n\t\n\t\$(document).ready(function() {\n\t\t\n\t\t\$('#pageselectButton').click(function() {\n\t\t\tvar pageNum = \$('#pageselect').val();\n\t\t\twindow.location = '" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&page='+pageNum+'&show=" . $_GET['show'] . "';\n\t\t});\n\t\n\t\t\$('#showselectButton').click(function() {\n\t\t\t\n\t\t\tvar showPerPage = \$('#showselect').val();\n\t\t\twindow.location = '" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&page=1&show='+showPerPage;\n\t\t\n\t\t});\n\t\n\t\n\t\t\n\t\t\$('#goUpLink').click(function() {\n\t\t\t\$('html, body').animate({ scrollTop: 0 });\n\t\t});\n\t\n\t});\n\n</script>\n\n";
Example #10
0
    exit;
}
// MEDALS
$arrMedals = $member->getMedalList(false, $websiteInfo['medalorder']);
$medalObj = new Medal($mysqli);
if (count($arrMedals) > 0) {
    foreach ($arrMedals as $medalID) {
        $medalObj->select($medalID);
        $medalInfo = $medalObj->get_info_filtered();
        if ($medalInfo['imagewidth'] == 0) {
            $imgInfo = getimagesize($medalObj->getLocalImageURL());
            $medalInfo['imagewidth'] = $imgInfo[0];
        }
        if ($medalInfo['imageheight'] == 0) {
            $imgInfo = getimagesize($medalObj->getLocalImageURL());
            $medalInfo['imageheight'] = $imgInfo[1];
        }
        $result = $mysqli->query("SELECT * FROM " . $dbprefix . "medals_members WHERE member_id = '" . $memberInfo['member_id'] . "' AND medal_id = '" . $medalInfo['medal_id'] . "'");
        $row = $result->fetch_assoc();
        $dispDateAwarded = "<b>Date Awarded:</b><br>" . getPreciseTime($row['dateawarded']);
        $dispReason = "";
        if ($row['reason'] != "") {
            $dispReason = "<br><br><b>Awarded for:</b><br>" . filterText($row['reason']);
        }
        $dispMedalMessage = "<b>" . $medalInfo['name'] . "</b><br><br>" . $dispDateAwarded . $dispReason;
        $tempArr = array("width" => $medalInfo['imagewidth'], "height" => $medalInfo['imageheight'], "url" => $medalInfo['imageurl'], "message" => $dispMedalMessage);
        $arrDispMedals[] = $tempArr;
    }
    $jsonMedals = json_encode($arrDispMedals);
    echo "\n\t\t<div class='formTitle' style='position: relative; text-align: center; margin-top: 20px'>Medals</div>\n\t\t\t<table class='profileTable' id='medalTable' style='border-top-width: 0px'>\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='main' align='center'>\n\t\t\t\t\t\t<p>\n\t\t\t\t\t\t\t<div id='medalDiv'>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</p>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t</table>\n\t\t\n\t\t\t\n\t\t\t<script type='text/javascript'>\n\t\t\t\tvar arrMedals = " . $jsonMedals . "\n\t\t\t\tvar medalHTML = \"\";\n\t\t\t\tvar divWidth = \$('#medalTable').width();\n\t\t\t\tvar countWidth = 0;\n\t\t\t\tvar arrMessage = [];\n\t\t\t\t\n\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\n\t\t\t\t\t\$.each(arrMedals, function(i, val) {\n\t\t\t\t\t\t\n\t\t\t\t\t\tcountWidth += parseInt(val.width);\n\t\t\t\t\t\tif(countWidth > divWidth) {\n\t\t\t\t\t\t\tmedalHTML += \"<br><br>\";\n\t\t\t\t\t\t\tcountWidth = 0;\n\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\t\n\t\t\t\t\t\tarrMessage[i] = val.message;\n\t\t\t\t\t\t//alert(arrMessage[i]);\n\t\t\t\t\t\tmedalHTML += \"<img src='\"+val.url+\"' width='\"+val.width+\"' height='\"+val.height+\"' style='margin: 0px 20px' onmouseover='showToolTip(arrMessage[\"+i+\"])' onmouseout='hideToolTip()'>\";\n\n\t\t\t\t\t});\n\t\t\t\t\n\t\t\t\t\t\$('#medalDiv').html(medalHTML);\n\t\t\t\t\t\n\t\t\t\t});\n\t\t\t\t\n\t\t\t</script>\n\t\t";
}
Example #11
0
        $pmObj->select($key);
        $pmInfo = $pmObj->get_info_filtered();
        $useAltBG = " alternateBGColor";
        if (isset($arrPMMID[$key]) && $multiMemPMObj->select($arrPMMID[$key]) && $multiMemPMObj->get_info("seenstatus") == 1) {
            $useAltBG = "";
        } elseif (!isset($arrPMMID[$key]) && $pmInfo['status'] == 1) {
            $useAltBG = "";
        }
        $addToPMValue = "";
        $addToPMURL = "";
        if (isset($arrPMMID[$key])) {
            $addToPMValue = "_" . $arrPMMID[$key];
            $addToPMURL = "&pmMID=" . $arrPMMID[$key];
        }
        $member->select($pmInfo['sender_id']);
        if ($_POST['folder'] == "-1" && $pmInfo['receiver_id'] != 0) {
            $member->select($pmInfo['receiver_id']);
            $dispSender = $member->getMemberLink();
            $member->select($memberInfo['member_id']);
        } elseif ($_POST['folder'] == "-1" && $pmInfo['receiver_id'] == 0) {
            $dispSender = $pmObj->getRecipients(true);
        } else {
            $dispSender = $member->getMemberLink();
        }
        echo "\n\t<tr>\n\t\t<td class='pmInbox main solidLine" . $useAltBG . "' style='padding-left: 0px' width=\"5%\"><input type='checkbox' value='" . $pmInfo['pm_id'] . $addToPMValue . "' class='textBox'></td>\n\t\t<td class='pmInbox main solidLine" . $useAltBG . "' style='overflow: hidden' width=\"30%\"><div style='width: 85%; white-space:nowrap; overflow: hidden; text-overflow: ellipsis'>" . $dispSender . "</a></div></td>\n\t\t<td class='pmInbox main solidLine" . $useAltBG . "' style='overflow: hidden' width=\"35%\"><div style='width: 85%; white-space:nowrap; overflow: hidden; text-overflow: ellipsis'><a href='" . $MAIN_ROOT . "members/privatemessages/view.php?pmID=" . $pmInfo['pm_id'] . $addToPMURL . "'>" . filterText($pmInfo['subject']) . "</a></div></td>\n\t\t<td class='pmInbox main solidLine" . $useAltBG . "' width=\"30%\">" . getPreciseTime($pmInfo['datesent']) . "</td>\n\t</tr>\n\t";
    }
    if (count($arrPM) == 0) {
        echo "\n\t<tr>\n\t\t<td class='main' colspan='4'>\n\t\t\t<p align='center' style='font-style: italic'>\n\t\t\t\tThis folder is empty!\n\t\t\t</p>\n\t\t</td>\n\t</tr>\n\n\t";
    }
    echo "</table>";
}
Example #12
0
 $newTopicBG = "";
 $dispNewTopicIMG = "";
 if ($LOGGED_IN && $boardObj->hasNewTopics($memberInfo['member_id'])) {
     $dispNewTopicIMG = " <img style='margin-left: 5px' src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/forum-new.png' title='New Posts!'>";
     $newTopicBG = " boardNewPostBG";
 }
 // Get Last Post Display Info
 if (count($arrForumTopics) > 0) {
     $boardObj->objPost->select($arrForumTopics[0]);
     $firstPostInfo = $boardObj->objPost->get_info_filtered();
     $boardObj->objTopic->select($firstPostInfo['forumtopic_id']);
     $lastPostID = $boardObj->objTopic->get_info("lastpost_id");
     $boardObj->objPost->select($lastPostID);
     $lastPostInfo = $boardObj->objPost->get_info_filtered();
     $postMemberObj->select($lastPostInfo['member_id']);
     $dispLastPost = "<div class='boardLastPostTitle'><a href='viewtopic.php?tID=" . $firstPostInfo['forumtopic_id'] . "#" . $lastPostID . "' title='" . $firstPostInfo['title'] . "'>" . $firstPostInfo['title'] . "</a></div>by " . $postMemberObj->getMemberLink() . "<br>" . getPreciseTime($lastPostInfo['dateposted']);
 } else {
     $dispLastPost = "<div style='text-align: center'>No Posts</div>";
 }
 $dispTopicCount = $boardObj->countTopics();
 $dispPostCount = $boardObj->countPosts();
 $arrDispSubForums = array();
 $arrSubForums = $boardObj->getSubForums();
 foreach ($arrSubForums as $value) {
     $subForumObj->select($value);
     $subForumInfo = $subForumObj->get_info_filtered();
     $arrDispSubForums[] = "<a href='" . $MAIN_ROOT . "forum/viewboard.php?bID=" . $value . "'>" . $subForumInfo['name'] . "</a>";
 }
 $dispSubForums = "";
 if (count($arrDispSubForums) > 0) {
     $dispSubForums = "<br><br><b>Sub-Forums:</b><br>&nbsp;&nbsp;" . implode("&nbsp;&nbsp;<b>|</b>&nbsp;&nbsp;", $arrDispSubForums);
    // 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("Member's Only Pages"));
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
$result = $mysqli->query("SELECT * FROM " . $dbprefix . "membersonlypage ORDER BY pagename");
if ($result->num_rows > 0) {
    echo "\n\t\n\t\t<table class='formTable' style='border-spacing: 0px; margin-bottom: 20px; margin-top: 2px'>\n\t\t\t<tr>\n\t\t\t\t<td class='formTitle' style='width: 40%; border-right: 0px'>Page Name:</td>\n\t\t\t\t<td class='formTitle' style='width: 40%; border-right: 0px'>Date Added:</td>\n\t\t\t\t<td class='formTitle' style='width: 20%'>Untag Page:</td>\n\t\t\t</tr>\n\t\t";
    $counter = 0;
    while ($row = $result->fetch_assoc()) {
        if ($counter == 0) {
            $addCSS = "";
            $counter = 1;
        } else {
            $addCSS = " alternateBGColor";
            $counter = 0;
        }
        echo "\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='main dottedLine" . $addCSS . "' style='padding-left: 5px; width: 40%'><a href='http://" . $row['pageurl'] . "' target='_blank'>" . filterText($row['pagename']) . "</a></td>\n\t\t\t\t\t<td class='main dottedLine" . $addCSS . "' style='width: 40%' align='center'>" . getPreciseTime($row['dateadded']) . "</td>\t\n\t\t\t\t\t<td class='main dottedLine" . $addCSS . "' style='width: 20%' align='center'><a href='javascript:void(0)' onclick=\"untagPage('" . $row['page_id'] . "')\"><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/delete.png' title='Untag Page' width='24' height='24'></a></td>\n\t\t\t\t</tr>\n\t\t\t";
    }
    echo "\n\t\t</table>\n\t\n\t";
} else {
    echo "\n\t\n\t\t<div class='shadedBox' style='margin: 20px auto; width: 40%'>\n\t\t\n\t\t\t<p align='center'>\n\t\t\n\t\t\t\t<i>There are currently no pages set to member's only!</i>\n\t\t\t\n\t\t\t</p>\n\t\t\t\n\t\t</div>\n\t\n\t";
}
Example #14
0
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
if (!defined("SHOW_PROFILE_MAIN")) {
    exit;
}
include_once $prevFolder . "plugins/youtube/youtube.php";
include_once $prevFolder . "plugins/youtube/ytbuttoncss.php";
$ytObj = new Youtube($mysqli);
if ($ytObj->hasYoutube($memberInfo['member_id'])) {
    $ytInfo = $ytObj->get_info_filtered();
    if ($ytInfo['showsubscribe'] + $ytInfo['showvideos'] > 0) {
        echo "\n\t\t\t\t\t<div class='formTitle' style='position: relative; text-align: center; margin-top: 20px'>Youtube</div>\n\t\t\t\t\t\n\t\t\t\t\t<table class='profileTable' style='border-top-width: 0px'>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='main' style='padding: 25px 0px'>\n\t\t\t\t\t\t\t<div id='loadingSpiralYTCache' class='loadingSpiral' style='padding-top: 0px'>\n\t\t\t\t\t\t\t\t<p align='center'>\n\t\t\t\t\t\t\t\t\t<img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/loading-spiral.gif'><br>Refreshing Data\n\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t";
        if ($ytInfo['showsubscribe'] == 1) {
            echo "\n\n\t\t\t\t\t<div id='ytInfoCard'>" . $ytObj->dispSubscribeButton() . "</div>\n\t\t\t\t\t<div style='font-style: italic; text-align: center; margin-top: 3px; margin-left: auto; margin-right: auto; margin-bottom: 25px; position: relative' class='main'>\n\t\t\t\t\t\tLast updated <span id='lastUpdateTime'>" . getPreciseTime($ytInfo['lastupdate']) . "</span>\n\t\t\t\t\t</div>\n\n\t\t\t\t";
        }
        if ($ytInfo['showvideos'] > 0) {
            echo "\n\n\t\t\t\t\t<div id='ytVideosContainer' class='ytProfileVideos'>\n\t\t\t\t\t\t<div style='position: absolute'>\n\t\t\t\t\t\t";
            $result = $mysqli->query("SELECT * FROM " . $dbprefix . "youtube_videos WHERE youtube_id = '" . $ytInfo['youtube_id'] . "' ORDER BY youtubevideo_id LIMIT " . $ytInfo['showvideos']);
            while ($row = $result->fetch_assoc()) {
                echo "<div class='ytVideo'><a href='http://www.youtube.com/watch?v=" . $row['video_id'] . "' target='_blank'><img src='" . $row['thumbnail'] . "' width='185' height='104' style='border: 0px'><p class='main' style='padding-top: 2px; margin-top: 0px'>" . $row['title'] . "</a></p></div>";
            }
            echo "\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t\t\n\t\t\t\t";
            echo "\n\t\t\t\t\t<div class='videoScroller'></div>\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\t\tvar videoHeight = 0;\n\t\t\t\t\t\t\t\$('.ytVideo').each(function(index) {\n\t\t\t\t\t\t\t\tif(\$(this).height() > videoHeight) {\n\t\t\t\t\t\t\t\t\tvideoHeight = \$(this).height();\n\t\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\$('#ytVideosContainer').css('height', videoHeight+'px');\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\tvar maxScroll = \$('#ytVideosContainer')[0].scrollWidth-\$('#ytVideosContainer').width();\n\t\t\t\t\t\t\tif(maxScroll > 0) {\n\t\t\t\t\t\t\t\t\$('.videoScroller').slider({\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tmax: maxScroll,\n\t\t\t\t\t\t\t\t\tslide: function(event, ui) {\n\t\t\t\t\t\t\t\t\t\t\$('#ytVideosContainer').scrollLeft(\$(this).slider('option', 'value'));\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\tchange: function(event, ui) {\n\t\t\t\t\t\t\t\t\t\t\$('#ytVideosContainer').scrollLeft(\$(this).slider('option', 'value'));\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}\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\n\t\t\t\t\t\n\t\t\t\t";
        }
        echo "\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t</table>\t\t\n\t\t\t\t";
        if (time() - $ytInfo['lastupdate'] > 1800) {
            echo "\n\t\t\t\t\t\n\t\t\t\t\t<script type='text/javascript'>\n\t\t\t\t\t\n\t\t\t\t\t\t\$(document).ready(function() {\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$('#loadingSpiralYTCache').show();\n\t\t\t\t\t\t\t\$('#ytInfoCard').fadeOut(250);\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\$.post('" . $MAIN_ROOT . "plugins/youtube/reloadcache.php', { yID: '" . $ytInfo['youtube_id'] . "' }, function(data) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tpostResult = JSON.parse(data);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif(postResult['result'] == 'success') {\n\t\t\t\t\t\t\t\t\t\$('#ytInfoCard').html(postResult['html']);\n\t\t\t\t\t\t\t\t\t\$('#lastUpdateTime').html(postResult['time']);\n\t\n\t\t\t\t\t\t\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\$('#ytInfoCard').fadeIn(250);\n\t\t\t\t\t\t\t\t\$('#loadingSpiralYTCache').hide();\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tvar bubbleRight = (\$('.ytBubble').width()*-1)-20;\n\t\t\t\t\t\t\t\t\$('.ytBubble').css('right', bubbleRight+'px');\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\t});\n\t\t\t\t\t\n\t\t\t\t\t</script>\n\t\t\t\t\n\t\t\t\t";
        }
    }
Example #15
0
            $member->select($row['member_id']);
            $posterInfo = $member->get_info_filtered();
            if ($posterInfo['avatar'] == "") {
                $posterInfo['avatar'] = $MAIN_ROOT . "themes/" . $THEME . "/images/defaultavatar.png";
            } else {
                $posterInfo['avatar'] = $MAIN_ROOT . $posterInfo['avatar'];
            }
            if ($row['newstype'] == 1) {
                $dispNewsType = " - <span class='publicNewsColor' style='font-style: italic'>public</span>";
            } elseif ($row['newstype'] == 2) {
                $dispNewsType = " - <span class='privateNewsColor' style='font-style: italic'>private</span>";
            } elseif ($row['newstype'] == 3) {
                $dispNewsType = "";
            }
            $dispLastEdit = "";
            if ($member->select($row['lasteditmember_id'])) {
                $checkHTMLAccess = $member->hasAccess($checkHTMLConsoleObj);
                $dispLastEditTime = getPreciseTime($row['lasteditdate']);
                $dispLastEdit = "<span style='font-style: italic'>last edited by " . $member->getMemberLink() . " - " . $dispLastEditTime . "</span>";
            }
            $member->select($row['member_id']);
            if (!isset($checkHTMLAccess)) {
                $checkHTMLAccess = $member->hasAccess($checkHTMLConsoleObj);
            }
            $dispNews = $checkHTMLAccess ? parseBBCode($row['newspost']) : nl2br(parseBBCode(filterText($row['newspost'])));
            echo "\n\t\t\t\n\t\t\t\t<div class='newsDiv' id='newsDiv_" . $row['news_id'] . "'>\n\t\t\t\t\t<div class='postInfo'>\n\t\t\t\t\t\t<div style='float: left'><img src='" . $posterInfo['avatar'] . "' class='avatarImg'></div>\n\t\t\t\t\t\t<div style='float: left; margin-left: 15px'>posted by " . $member->getMemberLink() . " - " . getPreciseTime($row['dateposted']) . $dispNewsType . "<br>\n\t\t\t\t\t\t<span class='subjectText'>" . filterText($row['postsubject']) . "</span></div>\n\t\t\t\t\t\t<div style='clear: both'></div>\n\t\t\t\t\t</div>\n\t\t\t\t\t<br>\n\t\t\t\t\t<div class='dottedLine' style='margin-top: 5px'></div>\n\t\t\t\t\t<div class='postMessage'>\n\t\t\t\t\t\t" . utf8_decode($dispNews) . "\n\t\t\t\t\t</div>\n\t\t\t\t\t<div class='dottedLine' style='margin-top: 5px; margin-bottom: 5px'></div>\n\t\t\t\t\t<div class='main' style='margin-top: 0px; margin-bottom: 10px; padding-left: 5px'>" . $dispLastEdit . "</div>\n\t\t\t\t\t<p style='padding: 0px; margin: 0px' align='right'><b><a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&newsID=" . $row['news_id'] . "&action=edit'>EDIT</a> | <a href='javascript:void(0)' onclick=\"deleteNews('" . $row['news_id'] . "')\">DELETE</a></b></p>\n\t\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\t";
        }
    } else {
        echo "\n\t\t\t<div class='shadedBox' style='width: 300px; margin-left: auto; margin-right: auto'>\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\t<i>There are currently no news posts!</i>\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t";
    }
}
Example #16
0
            $addCSS = " alternateBGColor";
            $counter = 1;
        } else {
            $counter = 0;
        }
        $arrSpecialMenuItems['forumactivity'] .= "<div class='menusForumActivityItemWrapper dottedLine " . $addCSS . "'>";
        $menuMemberObj->select($row['member_id']);
        $forumMemberInfo = $menuMemberObj->get_info_filtered();
        $checkURL = parse_url($forumMemberInfo['avatar']);
        if ((!isset($checkURL['scheme']) || $checkURL['scheme'] == "") && $forumMemberInfo['avatar'] != "") {
            $forumMemberInfo['avatar'] = $MAIN_ROOT . $forumMemberInfo['avatar'];
        } elseif ($forumMemberInfo['avatar'] == "") {
            $forumMemberInfo['avatar'] = $MAIN_ROOT . "themes/rockyice/images/defaultavatar.png";
        }
        $arrSpecialMenuItems['forumactivity'] .= "\n\t\t\t<div class='menusForumActivityAvatarDiv'>\n\t\t\t\t<img src='" . $forumMemberInfo['avatar'] . "'>\n\t\t\t</div>";
        $arrSpecialMenuItems['forumactivity'] .= "\n\t\t\t<div class='menusForumActivityTextWrapper'>\n\t\t\t\t<div class='menusForumActivityPostTitle'>\n\t\t\t\t\t<a href='" . $MAIN_ROOT . "forum/viewtopic.php?tID=" . $row['forumtopic_id'] . "#" . $row['forumpost_id'] . "'>" . $menuTopicPostInfo['title'] . "</a>\n\t\t\t\t</div>\n\t\t\t\t<div class='menusForumActivityPoster'>\n\t\t\t\t\tby " . $menuMemberObj->getMemberLink() . "\n\t\t\t\t</div>" . getPreciseTime($row['dateposted']) . "\n\t\t\t</div>";
        $arrSpecialMenuItems['forumactivity'] .= "<div style='clear: both'></div></div>";
    }
    if ($postCount == 5) {
        break;
    }
}
$arrSpecialMenuItems['forumactivity'] .= "</div>";
define('SPECIAL_MENU_ITEM', serialize($arrSpecialMenuItems));
$LOGGED_IN = LOGGED_IN;
function dispMenu($intSectionNum)
{
    global $MAIN_ROOT, $LOGGED_IN, $mysqli, $shoutBoxPostLink, $shoutBoxDeleteLink, $shoutBoxEditLink, $arrShoutBoxIDs, $websiteInfo, $arrLoginInfo;
    echo "<div id='menuSection_" . $intSectionNum . "'>";
    $menuCatObj = new MenuCategory($mysqli);
    $menuItemObj = new MenuItem($mysqli);
Example #17
0
                }
            }
            if ($countErrors > 0) {
                $_POST = filterArray($_POST);
                $_POST['submit'] = false;
            }
        }
        if (!$_POST['submit'] && !$_POST['cancel']) {
            $squadNewsInfo = $squadNewsObj->get_info_filtered();
            if ($dispError != "") {
                echo "\n\t\t\t\t<div class='errorDiv'>\n\t\t\t\t<strong>Unable to edit shoutbox post because the following errors occurred:</strong><br><br>\n\t\t\t\t{$dispError}\n\t\t\t\t</div>\n\t\t\t\t";
            }
            echo "\n\t\t\t\n\t\t\t\t\t<table class='formTable'>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='formLabel' valign='top'>Message:</td>\n\t\t\t\t\t\t\t<td class='main'>\n\t\t\t\t\t\t\t\t<textarea rows='10' cols='55' class='textBox' id='message_" . $squadNewsInfo['squadnews_id'] . "'>" . $squadNewsInfo['newspost'] . "</textarea>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td class='main' align='center' colspan='2'><br><br>\n\t\t\t\t\t\t\t\t<input type='button' onclick=\"saveNewsPost('" . $squadNewsInfo['squad_id'] . "', '" . $squadNewsInfo['squadnews_id'] . "')\" value='Save' class='submitButton' style='width: 90px'><br><br>\n\t\t\t\t\t\t\t\t<a href='javascript:void(0)' onclick=\"cancelEdit('" . $squadNewsInfo['squad_id'] . "', '" . $squadNewsInfo['squadnews_id'] . "')\">Cancel</a>\n\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t</table>\n\t\t\t</form>\n\t\t\t\n\t\t\t";
        }
        if ($_POST['cancel']) {
            $squadNewsInfo = $squadNewsObj->get_info_filtered();
            $member->select($squadNewsInfo['member_id']);
            $squadMemberInfo = $member->get_info_filtered();
            if ($squadMemberInfo['avatar'] == "") {
                $squadMemberInfo['avatar'] = $MAIN_ROOT . "themes/" . $THEME . "/images/defaultavatar.png";
            }
            $dispLastEdit = "";
            if ($member->select($squadNewsInfo['lasteditmember_id'])) {
                $dispLastEditTime = getPreciseTime($squadNewsInfo['lasteditdate']);
                $dispLastEdit = "<span style='font-style: italic'>last edited by " . $member->getMemberLink() . " - " . $dispLastEditTime . "</span>";
            }
            $member->select($squadNewsInfo['member_id']);
            echo "\n\t\t\t<img src='" . $squadMemberInfo['avatar'] . "' class='avatarImg'>\n\t\t\t<div class='postInfo'>\n\t\t\tposted by " . $member->getMemberLink() . " - " . getPreciseTime($squadNewsInfo['dateposted']) . "\n\t\t\t</div>\n\t\t\t<br>\n\t\t\t<div class='dottedLine' style='margin-top: 5px'></div>\n\t\t\t<div class='postMessage'>\n\t\t\t" . nl2br(parseBBCode(filterText($squadNewsInfo['newspost']))) . "\n\t\t\t</div>\n\t\t\t<div class='dottedLine' style='margin-top: 5px; margin-bottom: 5px'></div>\n\t\t\t<div class='main' style='margin-top: 0px; margin-bottom: 10px; padding-left: 5px'>" . $dispLastEdit . "</div>\n\t\t\t<p style='padding: 0px; margin: 0px' align='right'><b><a href='javascript:void(0)' onclick=\"editNews('" . $squadNewsInfo['squad_id'] . "', '" . $squadNewsInfo['squadnews_id'] . "')\">EDIT</a> | <a href='javascript:void(0)' onclick=\"deleteNews('" . $squadNewsInfo['squad_id'] . "', '" . $squadNewsInfo['squadnews_id'] . "')\">DELETE</a></b></p>\n\t\t\t";
        }
    }
}
Example #18
0
                    $arrBoards = $categoryObj->getAssociateIDs();
                    foreach ($arrBoards as $boardID) {
                        $boardObj->select($boardID);
                        $boardObj->addMod($memberModInfo['member_id']);
                    }
                }
            } elseif (substr($_POST['bID'], 0, 6) == "board_") {
                $boardID = str_replace("board_", "", $_POST['bID']);
                if ($boardObj->select($boardID)) {
                    $boardObj->addMod($memberModInfo['member_id']);
                }
            }
        } elseif ($_POST['action'] == "delete") {
            if ($boardObj->select($_POST['bID'])) {
                $boardObj->removeMod($memberModInfo['member_id']);
            }
        }
        $result = $mysqli->query("SELECT * FROM " . $dbprefix . "forum_moderator WHERE member_id = '" . $memberModInfo['member_id'] . "' ORDER BY dateadded DESC");
        while ($row = $result->fetch_assoc()) {
            $boardObj->select($row['forumboard_id']);
            $boardInfo = $boardObj->get_info_filtered();
            echo "\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='main'>" . $boardInfo['name'] . "</td>\n\t\t\t\t\t<td class='main'>" . getPreciseTime($row['dateadded']) . "</td>\n\t\t\t\t\t<td class='main' align='center'><a href='javascript:void(0)' onclick=\"deleteMod('" . $row['forumboard_id'] . "', '" . $row['member_id'] . "')\" title='Remove'><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/delete.png' style='width: 24px; height: 24px'></a></td>\n\t\t\t\t</tr>\t\t\t\t\t\n\t\t\t";
        }
        if ($result->num_rows == 0) {
            echo "\n\t\t\t\t<tr>\n\t\t\t\t\t<td colspan='3' align='center'>\n\t\t\t\t\t\t<div class='shadedBox' style='width: 40%; margin: 20px auto'>\n\t\t\t\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\t\t\t\t<i>" . $memberModInfo['username'] . " is not a moderator for any board!</i>\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t";
        }
    } else {
        echo "\n\t\t\n\t\t\t\t<tr>\n\t\t\t\t\t<td colspan='3' align='center'>\n\t\t\t\t\t\t<div class='shadedBox' style='width: 40%; margin: 20px auto'>\n\t\t\t\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\t\t\t\t<i>No member selected!</i>\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t";
    }
    echo "\n\t\t</table>\n\t\t\n\t";
}
Example #19
0
    }
} else {
    $memberInfo = $member->get_info();
    $consoleObj->select($consoleObj->findConsoleIDByName("View Custom Form Submissions"));
    if (!$member->hasAccess($consoleObj)) {
        exit;
    }
}
$arrSubmissions = $customFormPageObj->getSubmissions();
foreach ($arrSubmissions as $submissionID) {
    $customFormPageObj->objSubmission->select($submissionID);
    if ($customFormPageObj->objSubmission->get_info("seenstatus") == 0) {
        $customFormPageObj->objSubmission->update(array("seenstatus"), array("1"));
    }
    $arrSubmissionDetail = $customFormPageObj->getSubmissionDetail($submissionID);
    echo "\n\t\n\t\n\t\t<div class='formDiv' style='margin-bottom: 30px'>\n\t\n\t\t\t<table class='formTable'>\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='formLabel'>Date Submitted:</td><td class='main'>" . getPreciseTime($arrSubmissionDetail['submitdate']) . "</td>\n\t\t\t\t</tr>\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='formLabel'>IP Address:</td><td class='main'>" . $arrSubmissionDetail['ipaddress'] . "</td>\n\t\t\t\t</tr>\n\t\t";
    foreach ($arrSubmissionDetail['components'] as $componentID => $formValue) {
        $customFormPageObj->objComponent->select($componentID);
        $componentInfo = $customFormPageObj->objComponent->get_info_filtered();
        if ($componentInfo['componenttype'] != "separator") {
            echo "\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='formLabel' valign='top'>" . $componentInfo['name'] . ":</td>";
            if (!is_array($formValue)) {
                echo "\n\t\t\t\t\t<td class='main' valign='top'>" . nl2br($formValue) . "</td>\n\t\t\t\t</tr>\n\t\t\t\t";
            } else {
                echo "\n\t\t\t\t\t<td class='main' valign='top'>\n\t\t\t\t\t";
                $counter = 1;
                foreach ($formValue as $multiValue) {
                    echo $counter . ". " . nl2br($multiValue) . "<br>";
                    $counter++;
                }
                echo "</td></tr>";
<?php

if (!defined("MAIN_ROOT")) {
    exit;
}
?>

<div class='donationMessage dottedLine<?php 
echo $css;
?>
'>

	<div class='donationMessagePic'>
	
		<?php 
echo $member->getProfilePic();
?>
	
	</div>

	<div class='donationMessageText'>
	
		<?php 
echo nl2br(parseBBCode($donationInfo['message'])) . "\n\t\t\t\n\t\t\t\t<br><br>\n\t\t\t\t\n\t\t\t\t<div class='tinyFont'><span class='donatorAmount'>" . $this->formatAmount($donationInfo['amount']) . "</span> donated by " . $dispDonatorName . "\n\t\t\t\t<br>\n\t\t\t\t" . getPreciseTime($donationInfo['datesent']) . "</div>\n\t\t\t\n\t\t\t";
?>
	
	</div>

</div>
Example #21
0
    $arrMessageComments = $eventObj->objEventMessage->getComments(" ORDER BY dateposted ASC");
    foreach ($arrMessageComments as $commentID) {
        if ($eventObj->objEventMessageComment->select($commentID) && $objMember->select($row['member_id'])) {
            $commentInfo = $eventObj->objEventMessageComment->get_info_filtered();
            $objMember->select($commentInfo['member_id']);
            $memInfo = $objMember->get_info_filtered();
            if ($memInfo['profilepic'] == "") {
                $dispProfilePic = $MAIN_ROOT . "themes/" . $THEME . "/images/defaultprofile.png";
            } else {
                $dispProfilePic = $MAIN_ROOT . $memInfo['profilepic'];
            }
            $dispDeleteMessage = "";
            if ($eventObj->memberHasAccess($memberInfo['member_id'], "managemessages")) {
                $dispDeleteMessage = " - <a href='javascript:void(0)' onclick=\"deleteMessage('" . $commentID . "', 'c')\">Delete</a>";
            }
            echo "\n\n\t\t\t<li class='dottedLine'>\n\t\t\t\t<div class='profilePic'><img src='" . $dispProfilePic . "'></div>\n\t\t\t\t<div class='main messageDiv'><b>" . $objMember->getMemberLink() . "</b><br>\n\t\t\t\t\t" . nl2br(parseBBCode($commentInfo['comment'])) . "<br>\n\t\t\t\t\t<div class='tinyFont' style='margin-top: 5px'>" . getPreciseTime($commentInfo['dateposted']) . $dispDeleteMessage . "</div>\n\t\t\t\t</div>\n\t\t\t\t<div style='clear: both'></div>\n\t\t\t</li>\n\n\t\t\t";
        }
    }
    echo "\n\t</ul>\n\t</li>\n\t";
    if ($eventObj->memberHasAccess($memberInfo['member_id'], "postmessages")) {
        $tempTextAreaID = "txtComment_" . $row['eventmessage_id'];
        $dispComment = "";
        if ($_POST['commentBox'][$tempTextAreaID] != "") {
            $dispComment = filterText($_POST['commentBox'][$tempTextAreaID]);
            $focusID = "#" . $tempTextAreaID;
        }
        echo "\n\t\t<li class='dashedLine'>\n\t\tComment:<br>\n\t\n\t\t<textarea id='txtComment_" . $row['eventmessage_id'] . "' class='textBox'>" . $dispComment . "</textarea>\n\t\t<p align='right' style='margin-top: 2px; margin-right: 3px;'><input type='button' onclick=\"postComment('" . $row['eventmessage_id'] . "')\" class='submitButton' value='Comment' style='width: 80px'></p>\n\t\n\t\t</li>\n\t\t";
    } else {
        echo "<li class='dashedLine'></li>";
    }
}
Example #22
0
	
	<table class='profileTable' style='width: 65%; margin-left: auto; margin-right: auto'>
		<tr>
			<td colspan='2' class='formTitle' align='center' style='padding: 0px; height: 20px; border: 0px'>Diplomacy Information</td>
		</tr>
		<tr>
			<td class='profileLabel alternateBGColor' valign='top'>Clan Name:</td>
			<td class='main' style='padding-left: 10px' valign='top'><?php 
echo $diplomacyInfo['clanname'];
?>
</td>
		</tr>
		<tr>
			<td class='profileLabel alternateBGColor' valign='top'>Date Added:</td>
			<td class='main' style='padding-left: 10px' valign='top'><?php 
echo getPreciseTime($diplomacyInfo['dateadded']);
?>
</td>
		</tr>
		<tr>
			<td class='profileLabel alternateBGColor' valign='top'>Status:</td>
			<td class='main' style='padding-left: 10px' valign='top'><?php 
echo $dispStatus;
?>
</td>
		</tr>
		<tr>
			<td class='profileLabel alternateBGColor' valign='top'>Leader(s):</td>
			<td class='main' style='padding-left: 10px' valign='top'><?php 
echo $diplomacyInfo['leaders'];
?>
Example #23
0
$dispOrderBY = isset($_POST['orderby']) && $_POST['orderby'] == "name" ? "ORDER BY name" : "ORDER BY dateuploaded ";
$dispOrderBY .= isset($_POST['dir']) && $_POST['dir'] == "asc" ? "ASC" : "DESC";
$editCatCID = $consoleObj->findConsoleIDByName("Manage Download Categories");
$addDLCID = $consoleObj->findConsoleIDByName("Add Download");
$totalDownloads = 0;
foreach ($arrDownloadCat as $catID => $catName) {
    $downloadCatObj->select($catID);
    $arrDownloads = $downloadCatObj->getAssociateIDs($dispOrderBY);
    if (count($arrDownloads) > 0) {
        echo "\n\t\t\t<tr>\n\t\t\t\t<td class='main manageList dottedLine' colspan='2' style='width: 76%'><b><u>" . $catName . "</u></b></td>\n\t\t\t\t<td class='main manageList dottedLine' align='center' style='width: 12%'><a href='" . $MAIN_ROOT . "members/console.php?cID=" . $addDLCID . "&catID=" . $catID . "'><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/add.png' class='manageListActionButton' title='Add Download to " . $catName . "'></a></td>\n\t\t\t\t<td class='main manageList dottedLine' align='center' style='width: 12%'><a href='" . $MAIN_ROOT . "members/console.php?cID=" . $editCatCID . "&action=edit&catID=" . $catID . "'><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/edit.png' class='manageListActionButton' title='Edit " . $catName . " Category'></a></td>\n\t\t\t</tr>\n\t\t";
        $altBGCount = 0;
        foreach ($arrDownloads as $dlID) {
            $downloadObj->select($dlID);
            $dlInfo = $downloadObj->get_info_filtered();
            if ($altBGCount == 0) {
                $addCSS = "";
                $altBGCount = 1;
            } else {
                $addCSS = " alternateBGColor";
                $altBGCount = 0;
            }
            $dispTime = getPreciseTime($dlInfo['dateuploaded']);
            echo "\n\t\t\t\t<tr>\n\t\t\t\t\t<td class='main manageList dottedLine" . $addCSS . "' style='width: 46%; padding-left: 10px; font-weight: bold'><a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&action=edit&dlID=" . $dlID . "'>" . $dlInfo['name'] . "</a></td>\n\t\t\t\t\t<td class='main manageList dottedLine" . $addCSS . "' style='width: 30%; padding-left: 5px'>" . $dispTime . "</td>\n\t\t\t\t\t<td class='main manageList dottedLine" . $addCSS . "' align='center' style='width: 12%'><a href='" . $MAIN_ROOT . "members/console.php?cID=" . $cID . "&action=edit&dlID=" . $dlID . "'><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/edit.png' class='manageListActionButton' title='Edit Download'></a></td>\n\t\t\t\t\t<td class='main manageList dottedLine" . $addCSS . "' align='center' style='width: 12%'><a href='javascript:void(0)' onclick=\"deleteDL('" . $dlID . "')\"><img src='" . $MAIN_ROOT . "themes/" . $THEME . "/images/buttons/delete.png' class='manageListActionButton'></a></td>\n\t\t\t\t</tr>\n\t\t\t";
            $totalDownloads++;
        }
    }
}
echo "</table>";
if ($totalDownloads == 0) {
    echo "\n\t\n\t\t<div class='shadedBox' style='margin: 20px auto; width: 40%'>\n\t\t\t<p class='main' align='center'>\n\t\t\t\t<i>No downloads added yet!</i>\n\t\t\t</p>\n\t\t</div>\n\t\n\t";
}
<?php

if (!defined("MAIN_ROOT")) {
    exit;
}
$donationMember = new Member($mysqli);
$dispMemberName = $donationMember->select($donationInfo['member_id']) ? $donationMember->getMemberLink() : "";
$dispName = $donationInfo['name'];
if ($donationInfo['name'] == "" && $dispMemberName == "") {
    $dispName = "Anonymous";
} elseif ($donationInfo['name'] != "" && $dispMemberName != "") {
    $dispName = $dispMemberName . " <i>(" . $donationInfo['name'] . ")</i>";
}
$dispMessage = $donationInfo['message'] == "" ? "None" : nl2br(parseBBCode($donationInfo['message']));
$i = 0;
$arrComponents = array("campaign" => array("type" => "custom", "html" => "<div class='formInput main'><a href='" . $campaignObj->getLink() . "'>" . $campaignInfo['title'] . "</a></div>", "sortorder" => $i++, "display_name" => "Campaign"), "datesent" => array("type" => "custom", "html" => "<div class='formInput main'>" . getPreciseTime($donationInfo['datesent']) . "</div>", "sortorder" => $i++, "display_name" => "Date Sent"), "paypalid" => array("type" => "custom", "html" => "<div class='formInput main'>" . $donationInfo['transaction_id'] . "</div>", "sortorder" => $i++, "display_name" => "PayPal Transaction ID"), "amount" => array("type" => "custom", "html" => "<div class='formInput main'>" . $campaignObj->formatAmount($donationInfo['amount']) . "</div>", "sortorder" => $i++, "display_name" => "Amount"), "donationfrom" => array("type" => "custom", "html" => "<div class='formInput main'>" . $dispName . "</div>", "sortorder" => $i++, "display_name" => "Donated From"), "message" => array("type" => "custom", "html" => "<div class='formInput main'>" . $dispMessage . "</div><br>", "sortorder" => $i++, "display_name" => "Message"));
$setupFormArgs = array("name" => "console-" . $cID . "-donationdetails-" . $donationInfo['donation_id'], "components" => $arrComponents);
Example #25
0
	<tr>
		<td class='formTitle'>Rank:</td>
		<td class='formTitle'>Username:</td>
		<td class='formTitle'>Main Game:</td>
		<td class='formTitle'>Inactive Since:</td>
	</tr>
<?php 
$result = $mysqli->query("SELECT " . $dbprefix . "members.member_id, " . $dbprefix . "ranks.ordernum FROM " . $dbprefix . "members, " . $dbprefix . "ranks WHERE " . $dbprefix . "members.rank_id = " . $dbprefix . "ranks.rank_id AND " . $dbprefix . "members.onia = '1' AND " . $dbprefix . "members.disabled = '0' AND " . $dbprefix . "members.rank_id != '1' ORDER BY " . $dbprefix . "ranks.ordernum DESC");
while ($row = $result->fetch_assoc()) {
    $member->select($row['member_id']);
    $rankObj->select($member->get_info("rank_id"));
    $memberListInfo = $member->get_info_filtered();
    $rankListInfo = $rankObj->get_info_filtered();
    $dispMainGame = "Not Set";
    if ($gameObj->select($memberListInfo['maingame_id'])) {
        $gameObj->refreshImageSize();
        $gameInfo = $gameObj->get_info_filtered();
        $dispMainGame = "<img src='" . $gameInfo['imageurl'] . "' width='" . $gameInfo['imagewidth'] . "' height='" . $gameInfo['imageheight'] . "' onmouseover=\"showToolTip('" . $gameInfo['name'] . "')\" onmouseout='hideToolTip()'>";
    }
    echo "\n\t\t\t<tr>\n\t\t\t\t<td class='main' align='center'>\n\t\t\t\t\t<img src='" . $rankListInfo['imageurl'] . "' width='" . $rankListInfo['imagewidth'] . "' height='" . $rankListInfo['imageheight'] . "' onmouseover=\"showToolTip('" . $rankListInfo['name'] . "')\" onmouseout='hideToolTip()'>\n\t\t\t\t</td>\n\t\t\t\t<td class='main'>" . $member->getMemberLink() . "</td>\n\t\t\t\t<td class='main' align='center'>" . $dispMainGame . "</td>\n\t\t\t\t<td class='main' align='center'>" . getPreciseTime($memberListInfo['inactivedate']) . "</td>\n\t\t\t</tr>\n\t\t\n\t\t";
}
?>
</table>

<?php 
if ($result->num_rows > 0) {
    echo "\n\t\t<p align='center'>\n\t\t\t<b>Total Inactive Members:</b>\t<?php echo {$result->num_rows}; ?>\n\t\t</p>\n\t";
} else {
    echo "\n\t\n\t\t<div class='shadedBox' style='width: 40%; margin: 20px auto'>\n\t\t\t<p class='main' align='center'>\n\t\t\t\tThere are currently no inactive members.\n\t\t\t</p>\n\t\t</div>\n\t\t\n\t";
}
include $prevFolder . "themes/" . $THEME . "/_footer.php";
Example #26
0
include_once "../../../../classes/forumboard.php";
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$rankObj = new Rank($mysqli);
$boardObj = new ForumBoard($mysqli);
$consoleObj = new ConsoleOption($mysqli);
$cID = $consoleObj->findConsoleIDByName("Post Topic");
$consoleObj->select($cID);
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    $memberInfo = $member->get_info_filtered();
    $rankObj->select($memberInfo['rank_id']);
    $posterRankInfo = $rankObj->get_info_filtered();
    $_POST['wysiwygHTML'] = str_replace("<?", "&lt;?", $_POST['wysiwygHTML']);
    $_POST['wysiwygHTML'] = str_replace("?>", "?&gt;", $_POST['wysiwygHTML']);
    $_POST['wysiwygHTML'] = str_replace("<script", "&lt;script", $_POST['wysiwygHTML']);
    $_POST['wysiwygHTML'] = str_replace("</script>", "&lt;/script&gt;", $_POST['wysiwygHTML']);
    if ($memberInfo['avatar'] == "") {
        $memberInfo['avatar'] = $MAIN_ROOT . "themes/" . $THEME . "/images/defaultavatar.png";
    } else {
        $memberInfo['avatar'] = $MAIN_ROOT . $memberInfo['avatar'];
    }
    $dispSetAvatarWidth = "";
    $dispSetAvatarHeight = "";
    if ($websiteInfo['forum_avatarwidth'] > 0) {
        $dispSetAvatarWidth = " width: " . $websiteInfo['forum_avatarwidth'] . $websiteInfo['forum_avatarwidthunit'] . ";";
    }
    if ($websiteInfo['forum_avatarheight'] > 0) {
        $dispSetAvatarHeight = " height: " . $websiteInfo['forum_avatarheight'] . $websiteInfo['forum_avatarheightunit'] . ";";
    }
    echo "\n\t\t<div class='breadCrumbTitle'>Preview - " . filterText($_POST['previewSubject']) . "</div>\n\t\t<table class='forumTable'>\n\t\t\t<tr>\n\t\t\t\t<td class='boardPosterInfo' valign='top'>\n\t\t\t\t\t<span class='boardPosterName'>" . $member->getMemberLink() . "</span><br>\n\t\t\t\t\t" . $posterRankInfo['name'] . "<br>\n\t\t\t\t\t<img src='" . $memberInfo['avatar'] . "' style='margin-top: 5px; margin-bottom: 5px;" . $dispSetAvatarWidth . $dispSetAvatarHeight . "'><br>\n\t\t\t\t\tPosts: " . $member->countForumPosts() . "\n\t\t\t\t</td>\n\t\t\t\t<td class='boardPostInfo' valign='top'>\n\t\t\t\t<div class='postTime'>Posted " . getPreciseTime(time()) . "</div>\n\t\t\t\t\n\t\t\t\t" . parseBBCode($_POST['wysiwygHTML']) . "\n\t\t\t\t\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\t<tr>\n\t\t\t\t<td class='boardPosterInfoFooter'></td>\n\t\t\t\t<td class='boardPostInfoFooter'></td>\n\t\t\t</tr>\n\t\t</table>\n\t";
}
Example #27
0
            $addCSS = " alternateBGColor";
            $counter = 1;
        } else {
            $counter = 0;
        }
        $arrSpecialMenuItems['forumactivity'] .= "<div class='dottedLine " . $addCSS . "' style='padding: 5px 5px'>";
        $menuMemberObj->select($row['member_id']);
        $forumMemberInfo = $menuMemberObj->get_info_filtered();
        $checkURL = parse_url($forumMemberInfo['avatar']);
        if ((!isset($checkURL['scheme']) || $checkURL['scheme'] == "") && $forumMemberInfo['avatar'] != "") {
            $forumMemberInfo['avatar'] = $MAIN_ROOT . $forumMemberInfo['avatar'];
        } elseif ($forumMemberInfo['avatar'] == "") {
            $forumMemberInfo['avatar'] = $MAIN_ROOT . "themes/orangegrunge/images/defaultavatar.png";
        }
        $arrSpecialMenuItems['forumactivity'] .= "<div style='float: left; width: 35px'><img src='" . $forumMemberInfo['avatar'] . "' style='width: 30px; height: 30px; border: solid black 1px'></div>";
        $arrSpecialMenuItems['forumactivity'] .= "<div class='main' style='float: left; width: 95px'><div style='font-size: 11px; overflow: hidden; text-overflow: ellipsis; width:95px'><a href='" . $MAIN_ROOT . "forum/viewtopic.php?tID=" . $row['forumtopic_id'] . "#" . $row['forumpost_id'] . "'>" . $menuTopicPostInfo['title'] . "</a></div><div style='overflow: hidden; text-overflow: ellipsis; width:95px; font-size: 10px'>by " . $menuMemberObj->getMemberLink() . "</div><span style='font-size: 10px'>" . getPreciseTime($row['dateposted']) . "</span></div>";
        $arrSpecialMenuItems['forumactivity'] .= "<div style='clear: both'></div></div>";
    }
    if ($postCount == 5) {
        break;
    }
}
$arrSpecialMenuItems['forumactivity'] .= "</div>";
define('SPECIAL_MENU_ITEM', serialize($arrSpecialMenuItems));
$LOGGED_IN = LOGGED_IN;
function dispMenu($intSectionNum)
{
    global $MAIN_ROOT, $LOGGED_IN, $mysqli, $shoutBoxPostLink, $shoutBoxDeleteLink, $shoutBoxEditLink, $arrShoutBoxIDs, $websiteInfo, $arrLoginInfo;
    echo "<div id='menuSection_" . $intSectionNum . "'>";
    $menuCatObj = new MenuCategory($mysqli);
    $menuItemObj = new MenuItem($mysqli);
Example #28
0
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$arrSquadPrivileges = $squadObj->arrSquadPrivileges;
// Check Login
$LOGIN_FAIL = true;
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj)) {
    $LOGIN_FAIL = false;
    $memberInfo = $member->get_info_filtered();
    if ($squadObj->memberHasAccess($memberInfo['member_id'], "acceptapps")) {
        $squadInfo = $squadObj->get_info_filtered();
        $counter = 0;
        $result = $mysqli->query("SELECT * FROM " . $dbprefix . "squadapps WHERE squad_id = '" . $squadInfo['squad_id'] . "' AND status = '0' ORDER BY applydate DESC");
        while ($row = $result->fetch_assoc()) {
            $member->select($row['member_id']);
            $newMemberInfo = $member->get_info_filtered();
            $squadObj->select($row['squad_id']);
            $squadInfo = $squadObj->get_info_filtered();
            if ($newMemberInfo['avatar'] == "") {
                $newMemberInfo['avatar'] = $MAIN_ROOT . "themes/" . $THEME . "/images/defaultavatar.png";
            }
            if (trim($row['message']) == "") {
                $row['message'] = "None";
            }
            echo "\n\t\t\t<div class='newsDiv'>\n\t\t\t\t<img src='" . $newMemberInfo['avatar'] . "' class='avatarImg'>\n\t\t\t\t<div class='postInfo'>\n\t\t\t\t\tFrom: " . $member->getMemberLink() . " - " . getPreciseTime($row['applydate']) . "<br>\n\t\t\t\t</div>\n\t\t\t\t<br>\n\t\t\t\t<div class='dottedLine' style='margin-top: 5px'></div>\n\t\t\t\t<div class='postMessage'>\n\t\t\t\t\t<b>Message:</b><br><br>\n\t\t\t\t\t<div style='padding-left: 15px'>" . nl2br(parseBBCode(filterText($row['message']))) . "</div>\n\t\t\t\t</div>\n\t\t\t\t<div class='dottedLine' style='margin-top: 5px; margin-bottom: 5px'></div>\n\t\t\t\t<p style='padding: 0px; margin: 0px' align='right'><b><a href='javascript:void(0)' onclick=\"decisionClicked('" . $row['squadapp_id'] . "', 'accept')\">APPROVE</a> | <a href='javascript:void(0)' onclick=\"decisionClicked('" . $row['squadapp_id'] . "', 'decline')\">DECLINE</a></b></p>\n\t\t\t</div>\n\n\t\t\t";
            $counter++;
        }
        if ($counter == 0) {
            echo "\n\t\t\t<div class='shadedBox' style='width: 300px; margin-top: 50px; margin-left: auto; margin-right: auto; font-style: italic'>\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\tThere are currently no pending squad applications!\n\t\t\t\t</p>\n\t\t\t\t</div>\n\t\t\t<br>\n\t\t\t";
        }
    }
}
Example #29
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
 *
 */
echo "\n\t<div id='commentsDiv'>\n";
$blnShowDeleteComment = false;
$manageNewsCID = $consoleObj->findConsoleIDByName("Manage News");
$consoleObj->select($manageNewsCID);
if (isset($memberInfo['member_id']) && $member->hasAccess($consoleObj)) {
    $blnShowDeleteComment = true;
}
foreach ($arrComments as $commentID) {
    $newsObj->objComment->select($commentID);
    $commentInfo = $newsObj->objComment->get_info_filtered();
    $member->select($commentInfo['member_id']);
    $dispDelete = "";
    if ($blnShowDeleteComment) {
        $dispDelete = " - <a href='javascript:void(0)' onclick=\"deleteComment('" . $commentID . "')\">DELETE</a>";
    }
    echo "\n\t\t\n\t\t\n\t\t<p class='main' style='margin-bottom: 40px'>\n\t\t" . $commentInfo['message'] . "<br>\n\t\t" . $member->getMemberLink() . " &nbsp; " . getPreciseTime($commentInfo['dateposted']) . $dispDelete . "\n\t\t</p>\n\t\t\n\t\n\t";
}
if (count($arrComments) == 0) {
    echo "\n\t\t<p class='main' align='center'><br><i>No Comments!</i></p>\n\t";
}
echo "</div>";
Example #30
0
 public function displayDonator($selectID, $isMember = true, $css = "")
 {
     $member = new Member($this->MySQL);
     $arrSymbols = $this->getCurrencySymbol();
     if ($isMember && $member->select($selectID)) {
         $dispDonatorInfo['name'] = $member->getMemberLink();
         $dispDonatorInfo['amount'] = $this->arrDonatorList[$selectID]['amount'];
         $dispDonatorInfo['lastdate'] = getPreciseTime($this->arrDonatorList[$selectID]['lastdate']);
         $dispDonatorInfo['lastdonation'] = $this->arrDonatorList[$selectID]['timesdonated'] > 1 ? "Last Donation: <span class='donatorAmount'>" . $this->formatAmount($this->arrDonatorList[$selectID]['lastdonation']) . "</span><br>" : "";
     } else {
         $this->donationObj->select($selectID);
         $donationInfo = $this->donationObj->get_info_filtered();
         $dispDonatorInfo['name'] = $donationInfo['name'] == "" ? "Anonymous" : $donationInfo['name'];
         $dispDonatorInfo['amount'] = $donationInfo['amount'];
         $dispDonatorInfo['lastdate'] = getPreciseTime($donationInfo['datesent']);
         $dispDonatorInfo['lastdonation'] = "";
     }
     include BASE_DIRECTORY . "plugins/donations/include/donator_template.php";
 }