diff --git a/application/controller/AdminController.php b/application/controller/AdminController.php new file mode 100644 index 0000000..342e69a --- /dev/null +++ b/application/controller/AdminController.php @@ -0,0 +1,32 @@ +_location('gate'); + } + + public function gateAction() + { + } + + public function loginAction() + { + if($this->_getParam('password') == '') + { + $_SESSION['logged'] = 1; + $this->_location('index'); + } + else + { + $this->_location('gate', null, array('wrongpassword' => '')); + } + + } + + public function logoutAction() + { + $_SESSION['logged'] = 0; + $this->_location('gate'); + } +}