本文整理匯總了PHP中UserService::controleerGebruiker方法的典型用法代碼示例。如果您正苦於以下問題:PHP UserService::controleerGebruiker方法的具體用法?PHP UserService::controleerGebruiker怎麽用?PHP UserService::controleerGebruiker使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類UserService
的用法示例。
在下文中一共展示了UserService::controleerGebruiker方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: session_start
<?php
session_start();
require_once "business/10-1.userservice.class.php";
if (isset($_GET["action"]) and $_GET["action"] === "login") {
$login = UserService::controleerGebruiker($_POST["txtLogin"], $_POST["txtPaswoord"]);
if ($login) {
$_SESSION["login"] = TRUE;
header("location: 10-1-geheim.php");
} else {
header("location: 10-1-loginform.php");
exit(0);
}
} else {
include "presentation/10-1-loginform.php";
}
示例2: session_start
<?php
session_start();
require_once "business/userservice.class.php";
if (isset($_GET["action"])) {
if ($_GET["action"] == "login") {
$gebruikersnaam = $_POST["gebruikersnaam"];
$wachtwoord = $_POST["wachtwoord"];
$resultaat = UserService::controleerGebruiker($gebruikersnaam, $wachtwoord);
if ($resultaat) {
$_SESSION["aangemeld"] = true;
header("Location: toongeheim.php");
exit(0);
} else {
header("Location: aanmelden.php");
exit(0);
}
}
} else {
include "presentation/loginform.php";
}