Hi Tim,
The call stack for actually sending this mail:
lib/model/Users.php - sendEmailConfirmation()
lib/model/EmailTemplates.php - send()
apps/frontend/lib/myMail.php - sendMail() <- sfMail calls are here
after your information i changed
//Change
/* if ( !defined('IS_PROD') || ( defined('IS_PROD') && !IS_PROD) ) {
if ( sfConfig::get('app_test_audit_addr') != '' ) {^M
$mail->addAddress( sfConfig::get('app_test_audit_addr') );^M
$body = 'Recipient: ' . $to . '<br />' . $body;
sfContext::getInstance()->getLogger()->log('Sending mail to
audit address: ' . sfConfig::get('app_test_audit_addr') );
} else {
sfContext::getInstance()->getLogger()->log('Constant IS_PROD is not
explicitly defined as true and no audit email address has been set in
app.yml');
return; // send nothing
}^M
} else {^M
$mail->addAddress($to);^M
}^M*/
^M
$mail->addAddress('$to');
Then it works
I may case the always jumbs into
sfContext::getInstance()->getLogger()->log('Constant IS_PROD is not
explicitly defined as true and no audit email address has been set in
app.yml');
return; // send nothing
Where and how did you define IS_PROD?
Daniel
2008/8/27 Daniel Jordan <dan...@in...>
> Receive Password by eMail was not working
>
> wiser_platform/apps/frontend/modules/mail/actions
> actions.class.php
>
> I changed it to check if there is a problem with something else:
>
> With the changes it works.
>
> $mail_domain = sfConfig::get('app_mail_domain');
> $user = $this->getRequest()->getAttribute('user');
>
> $mail = new sfMail();
>
> $mail->initialize();
> $mail->setMailer('sendmail');
> $mail->setCharset('utf-8');
>
> $mail->setSender('info@' . $mail_domain);
> $mail->setFrom('info@' . $mail_domain);
> $mail->addReplyTo('admin@' . $mail_domain);
>
> $mail->addAddress( $user->getEmail() );
>
> $mail->setSubject('Your new password');
> $mail->setBody('
> Dear '.$user->getName().',
>
> You are so absentminded. Next time, try to remember your password:
> '.$user->getpassword().'
>
> Regards,
> The My Company webmaster');
>
>
> // $this->username = $user->getName();
> // $this->password = $user->getNewpassword();
> $mail->send();
>
> $this->mail = $mail;
> }
>
> Is there a patch for this file?
>
> best regards
>
> Daniel
>
>
--
inovativa gmbh
Poinger Str. 37
85570 Markt Schwaben
|