any help with this problem?
i have this code:
public function authAction() {
$this->view->disable();
if ($this->request->isPost() == true) {
$this->request->getPost("user_name");
$this->request->getPost("user_password");
$o_user = \BtsUser::findFirst(array(
'userName = :userName: and password = :password:',
'bind' => array(
'userName' => $this->request->getPost("user_name"),
'password' => md5($this->request->getPost("user_password"))
)
));
if ($o_user === false) {
$this->flash->error("Incorrect credentials");
} else {
if (!$o_user->systemActive) {
throw new Exception("The system was deactivated.");
}
$this->session->set("user-name", "Michael");
...
}
}
}
Something like that? help!