From 32577da4624c036d1c4d8dca8feca9d23a051c8b Mon Sep 17 00:00:00 2001 From: oliver Date: Sun, 19 Apr 2015 11:45:52 +0200 Subject: [PATCH] add password repeat for user creation (issue #85) --- controllers/UsersController.inc | 4 ++++ views/html/users/create.tpl | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/controllers/UsersController.inc b/controllers/UsersController.inc index 5228d3c7..e889d4c9 100644 --- a/controllers/UsersController.inc +++ b/controllers/UsersController.inc @@ -414,6 +414,10 @@ if($this->Users->emailExists($email)) { $validation = $this->Validation->addValidationResult($validation, 'email', 'exist', true); } + $password = $this->request->getPostParam('password'); + if($password != $this->request->getPostParam('passwordrepeat')) { + $validation = $this->Validation->addValidationResult($validation, 'password', 'repeat', false); + } // Create if($validation === true) diff --git a/views/html/users/create.tpl b/views/html/users/create.tpl index 590dff3b..771b906d 100644 --- a/views/html/users/create.tpl +++ b/views/html/users/create.tpl @@ -6,8 +6,8 @@

- -