本文整理匯總了PHP中BaseUser::Authenticate方法的典型用法代碼示例。如果您正苦於以下問題:PHP BaseUser::Authenticate方法的具體用法?PHP BaseUser::Authenticate怎麽用?PHP BaseUser::Authenticate使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類BaseUser
的用法示例。
在下文中一共展示了BaseUser::Authenticate方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: gettext
include_once "{$BASE_path}/base_db_common.php";
include_once "{$BASE_path}/base_common.php";
$errorMsg = "";
$displayError = 0;
$noDisplayMenu = 1;
// Redirect to base_main.php if auth system is off
if ($Use_Auth_System == 0) {
base_header("Location: base_main.php");
}
if (isset($_POST['submit'])) {
$debug_mode = 0;
// wont login with debug_mode
$BASEUSER = new BaseUser();
$user = filterSql($_POST['login']);
$pwd = filterSql($_POST['password']);
if ($BASEUSER->Authenticate($user, $pwd) == 0) {
header("Location: base_main.php");
exit;
}
} else {
$displayError = 1;
$errorMsg = gettext("User does not exist or your password was incorrect!<br>Please try again");
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- <?php
echo gettext("Forensics Console " . $BASE_installID) . $BASE_VERSION;
?>
-->
<html>