Nope, still doesn't work. This seems like a lot of hassle/steps in
between just to do something simple like update.
Heres a snippet of my code:
if ($this->User->validates()) {
$userObj = $this->User->find('first', array(
'conditions' => array(
'User.username' => $this->data['User']['username'],
'User.password' => $this->data['User']['password'],
'User.hash' => $hash
),
'fields' => array('User.id', 'User.signupDate')
));
if (!empty($userObj)) {
$this->User->create();
$this->User->id = $userObj['User']['id'];
if ($this->User->verifyEmail($userObj['User']['signupDate'],
$this->Settings->grab('email_verify_exp_hours'))) {
$this->User->saveField('status', 'active');
} else {
$this->User->invalidate('', sprintf(__d('errors',
'verifyTimeElapsed', true), $this->Settings->grab
('email_verify_exp_hours')));
$this->User->saveField('status', 'inactive');
}
} else {
$this->User->invalidate('', __d('errors', 'verifyFailure',
true));
}
}
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---