summaryrefslogtreecommitdiff
path: root/framework/Wsat/pages/TWsatLogin.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Wsat/pages/TWsatLogin.php')
-rw-r--r--framework/Wsat/pages/TWsatLogin.php15
1 files changed, 7 insertions, 8 deletions
diff --git a/framework/Wsat/pages/TWsatLogin.php b/framework/Wsat/pages/TWsatLogin.php
index 0bbdc53f..69f8cc39 100644
--- a/framework/Wsat/pages/TWsatLogin.php
+++ b/framework/Wsat/pages/TWsatLogin.php
@@ -8,8 +8,11 @@
class TWsatLogin extends TPage {
public function login() {
- if ($this->IsValid) {
- $this->Session["wsat_password"] = $this->getService()->getPassword();
+ $config_pass = $this->getService()->getPassword();
+ $user_pass = $this->password->Text;
+
+ if ($user_pass === $config_pass) {
+ $this->Session["wsat_password"] = $config_pass;
$authManager = $this->Application->getModule('auth');
$url = $authManager->ReturnUrl;
@@ -17,15 +20,11 @@ class TWsatLogin extends TPage {
$url = $this->Service->constructUrl('TWsatHome');
}
$this->Response->redirect($url);
+ } else {
+ echo "user or pass wrong";
}
}
- public function validatePassword($sender, $param) {
- $config_pass = $this->getService()->getPassword();
- $user_pass = $this->password->Text;
- $param->IsValid = $user_pass === $config_pass;
- }
-
}
?> \ No newline at end of file