summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-03-16 08:05:44 +0000
committerBharat Mediratta <bharat@menalto.com>2009-03-16 08:05:44 +0000
commitc15e4c61a380094314290e0b7aec4646fabd0abc (patch)
tree2f17b6b90c7434f69672cd7de379272a53088610
parent54e07d07691be42f606b5a5346bf956257c598bd (diff)
Proxy the url through _auth() to user::get_login_form()
-rw-r--r--modules/user/controllers/login.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/user/controllers/login.php b/modules/user/controllers/login.php
index 12301ce5..86842a9a 100644
--- a/modules/user/controllers/login.php
+++ b/modules/user/controllers/login.php
@@ -26,7 +26,7 @@ class Login_Controller extends Controller {
}
public function auth_ajax() {
- list ($valid, $form) = $this->_auth();
+ list ($valid, $form) = $this->_auth("login/auth_ajax");
if ($valid) {
print json_encode(
array("result" => "success",
@@ -43,7 +43,7 @@ class Login_Controller extends Controller {
}
public function auth_html() {
- list ($valid, $form) = $this->_auth();
+ list ($valid, $form) = $this->_auth("login/auth_html");
if ($valid) {
url::redirect("albums/1");
} else {
@@ -51,8 +51,8 @@ class Login_Controller extends Controller {
}
}
- private function _auth() {
- $form = user::get_login_form();
+ private function _auth($url) {
+ $form = user::get_login_form($url);
$valid = $form->validate();
if ($valid) {
$user = ORM::factory("user")->where("name", $form->login->inputs["name"]->value)->find();