if($this->User->saveField('reset_password_token',$fu['User']['reset_password_token'])){
$Email = new CakeEmail();
$Email->to("[email protected]");
$Email->subject("Password Reset Request - DO NOT REPLY");
$Email->replyTo("[email protected]");
$Email->from('[email protected]');
$Email->sender('[email protected]', 'Do Not Reply');
$Email->template("resetpw");
$Email->emailFormat("html");
$Email->send('Do not reply');
$this->Session->setFlash(__('Check your email to reset your password.', true));
saveField工作並更新表格和閃光消息'檢查您的電子郵件以重置您的密碼'。也顯示,但電子郵件永遠不會被髮送。我如何使電子郵件工作?這是cakephp版本2.電子郵件不被髮送CakePHP
你在哪裏指定電子郵件網關? –
謝謝。什麼是電子郵件網關? –
我也在使用這個:App :: uses('CakeEmail','Network/Email'); –