Пример #1
0
 function sendSignupMessage($options = array())
 {
     $default_options = array('signup_message' => 'registration_details');
     $options = array_merge($default_options, $options);
     if (!empty($options['signup_message'])) {
         Ak::import_mailer('account_mailer');
         $Mailer =& new AccountMailer();
         $Mailer->_login = $options['login'];
         $Mailer->_password = $options['password'];
         $Mailer->deliver($options['signup_message'], $this->get('email'));
     }
 }
Пример #2
0
 function sendPasswordReminder($User)
 {
     if ($password_reset_url = $this->getCredentialsRenewalUrl($User)) {
         Ak::import_mailer('account_mailer');
         $Mailer =& new AccountMailer();
         $Mailer->setPasswordResetUrl($password_reset_url);
         $Mailer->deliver('password_reminder', $User->get('email'));
         return true;
     }
     return false;
 }
Пример #3
0
 function setup()
 {
     Ak::import_mailer('render_mailer,first_mailer,second_mailer,helper_mailer,test_mailer');
     $this->Mailer =& new AkActionMailer();
     $this->Mailer->delivery_method = 'test';
     $this->Mailer->perform_deliveries = true;
     $this->Mailer->deliveries = array();
     $this->recipient = 'test@localhost';
 }
Пример #4
0
function __autoload($class_name)
{
    if (strstr($class_name, 'Mailer')) {
        Ak::import_mailer($class_name);
    } else {
        Ak::import($class_name);
    }
}