# |
Sep 13th 2009, 12:37 |
NoReGreT |
TehTreag: so find(x, y) finds x in y ? |
# |
Sep 13th 2009, 12:37 |
ionas |
but you can do it in model space/domain too |
# |
Sep 13th 2009, 12:37 |
ionas |
justskills, that code above was in controller space |
# |
Sep 13th 2009, 12:37 |
kahwee |
thanks guys, i reported it here: http://code.cakephp.org/tickets/view/85 |
# |
Sep 13th 2009, 12:37 |
ionas |
i'd rather put it in beforeValidate |
# |
Sep 13th 2009, 12:36 |
TehTreag |
justskills: See the beforeSave() here in his user model. http://tr.im/yACt |
# |
Sep 13th 2009, 12:35 |
justskills |
ionas: in the beforeFilter of the controller? |
# |
Sep 13th 2009, 12:35 |
justskills |
ionas: where did you put that code? |
# |
Sep 13th 2009, 12:34 |
TehTreag |
NoReGreT: An array with the fields id and username, provided it can find a match by username, and md5 hashed password? |
# |
Sep 13th 2009, 12:33 |
NoReGreT |
what does it return |
# |
Sep 13th 2009, 12:33 |
NoReGreT |
what does this mean, $this->find(array('username' => $data['username'], 'password' => md5($data['password'])), array('id', 'username')); I'm lost, it's in a model |
# |
Sep 13th 2009, 12:32 |
TehTreag |
ionas: Sure, the same way recommended in teknoid's article. |
# |
Sep 13th 2009, 12:30 |
NoReGreT |
thanks |
# |
Sep 13th 2009, 12:29 |
ionas |
This is how I did user registration http://github.com/ionas/sna/blob/d438d956775ed6cdbb427b0c1595741b2641c620/www/app/controllers/users_controller.php |
# |
Sep 13th 2009, 12:29 |
ionas |
NoReGreT, why not? |
# |
Sep 13th 2009, 12:28 |
kahwee |
it's just a minor bug, missing character |
# |
Sep 13th 2009, 12:28 |
kahwee |
of course, haha |
# |
Sep 13th 2009, 12:27 |
TehTreag |
Duh. |
# |
Sep 13th 2009, 12:27 |
ionas |
first make sure that is a bug ;-) |
# |
Sep 13th 2009, 12:27 |
TehTreag |
kahwee: Submit a ticket - http://code.cakephp.org/tickets |
# |
Sep 13th 2009, 12:26 |
kahwee |
hi, how do i submit a bug report? |
# |
Sep 13th 2009, 12:24 |
NoReGreT |
best thing to do for adding users is creating an add() action in the userscontroller ? (using auth ie) |
# |
Sep 13th 2009, 12:20 |
ionas |
the above "unset" should be before your validation/save call from controller |
# |
Sep 13th 2009, 12:19 |
ionas |
any idea: $foo = "EnglishTranslateString" __('Bar') . howToTranslateThisFromPoFiles($foo) . __('Quux')? |
# |
Sep 13th 2009, 12:17 |
ionas |
changing email, and password, accepting terms of service are separated from "other" user details she can edit |
# |
Sep 13th 2009, 12:16 |
ionas |
justskills, I have different actions for different user details |
# |
Sep 13th 2009, 12:16 |
ionas |
my way: if(isset($this->data['User']['password']) andand empty($this->data['User']['password'])) { unset($this->data['User']['password'] }; |
# |
Sep 13th 2009, 12:16 |
TehTreag |
justskills: Try teknoid's article - http://teknoid.wordpress.com/2008/10/08/demystifying-auth-features-in-cakephp-12/ |
# |
Sep 13th 2009, 12:16 |
justskills |
i mean i want to save the user but the password sould stay the same |
# |
Sep 13th 2009, 12:15 |
ionas |
in that case its controller work |
# |
Sep 13th 2009, 12:15 |
ionas |
justskills, well |
# |
Sep 13th 2009, 12:15 |
ionas |
justskills, overwrite hashPasswords |
# |
Sep 13th 2009, 12:15 |
justskills |
but i want to have the option. If i enter a password i reset it, but i i dont enter any password i just don't wanna save |
# |
Sep 13th 2009, 12:14 |
justskills |
i want to edit a user and save without enter a new password |
# |
Sep 13th 2009, 12:13 |
TehTreag |
justskills: What's the issue? |
# |
Sep 13th 2009, 12:13 |
justskills |
guys i have no problem with validation |
# |
Sep 13th 2009, 12:11 |
TehTreag |
~tell justskills about google cakephp auth password validate |
# |
Sep 13th 2009, 12:10 |
TehTreag |
justskills: There are a few articles (try google) on validating passwords. I don't think there is any other case to disable it. |
# |
Sep 13th 2009, 12:08 |
justskills |
the auth component encrypts a empty password field. how can i disable that? |
# |
Sep 13th 2009, 12:08 |
justskills |
hey |
# |
Sep 13th 2009, 12:00 |
ionas |
any tip on how to translate a value of a variable like $messagesTitle (the value will be in english but should be translated using po files, like the __() usage) |