예제 #1
0
$appComponentObj = $memberAppObj->objAppComponent;
$appSelectValueObj = new Basic($mysqli, "app_selectvalues", "appselectvalue_id");
$profileOptionObj = new ProfileOption($mysqli);
if ($member->select($_SESSION['btUsername']) && $member->authorizeLogin($_SESSION['btPassword']) || $websiteInfo['memberregistration'] == 1) {
    echo "\n\t\t<script type='text/javascript'>\n\t\t\twindow.location = '" . $MAIN_ROOT . "'\n\t\t</script>\n\t";
    exit;
}
$breadcrumbObj->setTitle("Sign Up");
$breadcrumbObj->addCrumb("Home", $MAIN_ROOT);
$breadcrumbObj->addCrumb("Sign Up");
include $prevFolder . "include/breadcrumb.php";
include BASE_DIRECTORY . "include/signup_form.php";
if ($_POST['submit']) {
    $additionalSuccessInfo = "<br><br>You must wait to be approved by a member to become a full member on the website.";
    if ($memberAppObj->save() && $websiteInfo['memberapproval'] == 0) {
        $memberAppObj->addMember();
        $additionalSuccessInfo = "<br><br>You may now log in to your account.";
    }
    if ($_POST['submit']) {
        $signUpForm->saveMessage = "<span class='main'>" . $signUpForm->saveMessage . $additionalSuccessInfo . "</span>";
        $signUpForm->showSuccessDialog();
    }
}
if (!$_POST['submit']) {
    $signUpForm->show();
    echo "\n\t<script type='text/javascript'>\n\t\n\t\t\$(document).ready(function() {\n\t\t\n\t\t\t\$(\"a[data-refresh='1']\").click(function() {\n\t\t\t\t\t\t\n\t\t\t\tvar imgDivID = '#'+\$(this).attr('data-image');\n\t\t\t\t\n\t\t\t\t\$(imgDivID).fadeOut(250);\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\$.post('" . $MAIN_ROOT . "images/captcha.php?display=1&appCompID='+\$(this).attr('data-appid'), { }, function(data) {\n\t\t\t\t\t\$(imgDivID).html(data);\n\t\t\t\t\t\$(imgDivID).fadeIn(250);\n\t\t\t\t});\n\t\t\t\t\n\t\t\t});\n\t\t\n\t\t});\n\t\n\t</script>\n\t\n\t";
}
?>

<?php 
include $prevFolder . "themes/" . $THEME . "/_footer.php";
예제 #2
0
 *
 * License: http://www.bluethrust.com/license.php
 *
 */
include_once "../../../../_setup.php";
include_once "../../../../classes/member.php";
include_once "../../../../classes/basic.php";
include_once "../../../../classes/rank.php";
$consoleObj = new ConsoleOption($mysqli);
$member = new Member($mysqli);
$member->select($_SESSION['btUsername']);
$memberInfo = $member->get_info_filtered();
$cID = $consoleObj->findConsoleIDByName("View Member Applications");
$consoleObj->select($cID);
$memberAppObj = new MemberApp($mysqli);
if ($member->authorizeLogin($_SESSION['btPassword']) && $member->hasAccess($consoleObj) && $memberAppObj->select($_POST['mAppID'])) {
    $arrMemAppInfo = $memberAppObj->get_info_filtered();
    if ($memberAppObj->addMember()) {
        $newMemberInfo = $memberAppObj->getNewMemberInfo();
        $dispNewMember = $newMemberInfo['username'];
        $member->logAction("Accepted " . $dispNewMember . "'s member application.");
        if ($newMemberInfo['recruiter'] == 0) {
            $memberAppObj->setRecruiter($memberInfo['member_id']);
        }
        echo "\n\t\t\t<div id='memAppMessage'>\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\t" . $dispNewMember . " was successfully added to the website!\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t";
    } else {
        echo "\n\t\t\t<div id='memAppMessage'>\n\t\t\t\t<p class='main' align='center'>\n\t\t\t\t\tUnable to accept " . $dispNewMember . "'s application!  Please contact the website administrator.\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t";
    }
    echo "\n\t\t\n\t\t<script type='text/javascript'>\n\t\t\t\$(document).ready(function() {\n\t\t\t\n\t\t\t\t\$('#memAppMessage').dialog({\n\t\t\t\t\n\t\t\t\t\ttitle: 'Accept Member Application',\n\t\t\t\t\tmodal: true,\n\t\t\t\t\tzIndex: 99999,\n\t\t\t\t\tshow: 'scale',\n\t\t\t\t\twidth: 400,\n\t\t\t\t\tresizable: false,\n\t\t\t\t\tbuttons: {\n\t\t\t\t\t\t'OK': function() {\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\n\t\t\t\t});\n\t\t\t\n\t\t\t});\t\t\n\t\t</script>\n\t";
}
include "memberapplist.php";