if ($USERLOGGEDIN == true) { $BODY .= "Login Successful! <a href='index.php?page=home'>Click Here</a>."; } else { $BODY .= "Login Failed! Try Again.<br/>" . getLoginForm(); } } else { if ($page == "logout") { require_once "ui/login.lib.php"; $BODY .= logout($USERLOGGEDIN); } } require_once "ui/static.php"; if ($page == "home") { if ($USERLOGGEDIN == false) { require_once "ui/login.lib.php"; $BODY .= getLoginForm(); } else { require_once "ui/etc.lib.php"; $BODY .= getHomePage($USERLOGGEDIN); } } else { if ($page == "challenges") { require_once "ui/challenges.lib.php"; $BODY .= getChallenges($USERLOGGEDIN); } else { if ($page == "contact") { require_once "ui/etc.lib.php"; $BODY .= getContactPage($USERLOGGEDIN); } } }
$txt .= "</form>\n"; return $txt; } verifyMethodPost(); # check if all the POST variables are present (login, pwd) verifyPostVarExists('login'); verifyPostVarExists('pwd'); $login = stripQuotes(myUrlDecode(getPostVar('login'))); $pwd = stripQuotes(myUrlDecode(getPostVar('pwd'))); $productList = getProductsForLoginPwd($login, $pwd); if (0 == count($productList)) { echo "<b><font color=\"red\">The login '{$login}' and password '{$pwd}' combination didn't match anything in our database.\n"; echo "Please try again. </font></b>\n"; echo "If problem persists, please e-mail <a href=\"mailto:support@arslexis.com\">ArsLexis</a>\n"; echo "<p>\n"; echo getLoginForm(); $subject = "[PAYPAL ERROR] failed login"; $body = "Failed attempt to login using login='******' and pwd='{$pwd}'\n"; $body .= getInterestingVars(); sendEmail(MYEMAIL, $subject, $body); } else { # display a list of products with links to download echo "<table>\n<tr>\n"; echo "<td width=\"30\"> </td>\n<td>\n"; echo "<table>\n"; foreach ($productList as $name => $dlCount) { $fullName = getProductFullName($name); $dlUrl = "dl-2.php?login="******"&pwd=" . urlencode($pwd) . "&name=" . urlencode($name); echo "<tr>\n"; echo " <td valign=\"top\"><img src=\"/gfx2/black_bullet.gif\"> {$fullName} </td>\n"; echo " <td><a href=\"{$dlUrl}\">Download</a></td>\n";
/** * Display 'Logout' page. */ function pageLogout() { global $PIVOTX; $PIVOTX['session']->logout(); $PIVOTX['template']->assign('title', __('Log out')); $PIVOTX['template']->assign('heading', __('Log out')); $PIVOTX['messages']->addMessage(__('You are now logged out of PivotX')); $form = getLoginForm(); $PIVOTX['template']->assign("form", $form->fetch(true)); renderTemplate('generic.tpl'); }
if (isLogin($challenge, $response)) { if (checkLogin($challenge, $response)) { doLogin(); header("Location: {$_SERVER['PHP_SELF']}"); exit; } else { echo getLoginForm("Login failed."); echo "</body></html>"; exit; } } unset($password, $challenge, $response); // ############################################## // auth-check if (!checkAuth()) { echo getLoginForm("Please login"); echo "</body></html>"; exit; } updateSession(); // ############################################## // execute menu commands foreach ($_REQUEST as $key => $val) { if (isset($_SERVER['SOLAR_CONFIG']['MENU'][$key]) && $val == 1) { $label = ucfirst(strtolower($key)); $command = $_SERVER['SOLAR_CONFIG']['MENU'][$key]; echo <<<EOC \t\t<div class="menu-command"> \t\t\t<h2>{$label}</h2> \t\t\t<p> \t\t\t\t<label>executing <code>{$command}</code> ...</label>
<?php require_once 'conf.php'; require_once 'lib.php'; $error = ""; if (getField('submit') == "Login") { if (isValidUser()) { setLogin(); header("Location: index.php"); } else { $error = "Invalid Username or Password!"; } } $conf['pageTitle'] .= " | SignUp"; $data['menu'] = getTopMenu(); $data['bodyContent'] = getLoginForm($error); require_once TEMPLATE; function getLoginForm($error) { $temp = '<div class="title">User Login</div> <div class="form login-form"> <div class="errors">' . $error . '</div> <form action="login.php" method="post" id="login_form"> <div class="field"> <label for="username">Username</label><br/> <input type="text" name="username" id="username"/> </div> <div class="field"> <label for="password">Password</label><br/> <input type="password" name="password" id="password"/> </div>
if (strcasecmp("article", $type) === 0 && $articleTypeSwitch == false) { $output .= "<tr><th colspan='3'><h1>Article</h1></th></tr>\r\n\t\t\t\t<tr><th>Location</th><th>Username</th><th>Password</th>"; $articleTypeSwitch = true; } } $accountUserName = $userAccount->getAccountUserName($location); $accountPassword = $userAccount->getAccountPassword($location); $accountUserValue = ''; $accountPasswordValue = ''; if (isset($accountUserName)) { $accountUserValue = "value='{$accountUserName}'"; } if (isset($accountPassword)) { $accountPasswordValue = "value='{$accountPassword}'"; } $disabled = ""; if (!$working) { $style = "STYLE='color: #FFFFFF; background-color: #808080;'"; $disabled = "disabled {$style}"; } $output .= "<tr><td><b>{$location}</b></td><td align='center'><input type='text' {$disabled} name='{$location}-userName' {$accountUserValue}></td><td align='center'><input class='pw' type='text' {$disabled} name='{$location}-password' {$accountPasswordValue}></td></tr>"; } $output .= "<tr><td colspan='3' align='center'><input type='button' value='Save' onClick='update();'><input type='checkbox' value='' name='pwBox' onClick='passwordChange();' checked> Show Passwords</td></tr>\r\n\t\t</table>\r\n\t\t</form>"; } else { $output .= "<font color='red'><b>Error Logging In</b></font><br>" . getLoginForm(); } } else { $output .= getLoginForm(); } $output .= "</body></html>"; echo $output;