Package com.dotmarketing.util

Examples of com.dotmarketing.util.Mailer.sendMessage()


      String subject) {
    Mailer m = new Mailer();
    m.setToEmail(to);
    m.setFromEmail(from);
    m.setSubject(subject);
    return m.sendMessage();
  }

  public ActionForward back(ActionMapping mapping, ActionForm lf,
      HttpServletRequest request, HttpServletResponse response)
      throws Exception {
View Full Code Here


      Mailer m = new Mailer();
      m.setToEmail(user.getEmailAddress());
      m.setSubject("Your " + host.getHostname() + " Password");
      m.setHTMLBody(message);
      m.setFromEmail(Config.getStringProperty("EMAIL_SYSTEM_ADDRESS"));
      return m.sendMessage();
    } catch (Exception e) {
      Logger.warn(EmailFactory.class, e.toString(), e);
      return false;
    }
View Full Code Here

              m.addAttachment(f, entry.getKey() + "." + UtilMethods.getFileExtension(f.getName()));
            }
          }
        }

        if (m.sendMessage()) {

          // there is an auto reply, send it on
          if ((UtilMethods.isSet((String)getMapValue("autoReplyTemplate", parameters)) ||
              UtilMethods.isSet((String)getMapValue("autoReplyText", parameters)))
              && UtilMethods.isSet((String)getMapValue("autoReplySubject", parameters))
View Full Code Here

                else
                  m.setHTMLBody(emailBodies.get("emailHTMLTableBody"));
              }
              m.setTextBody(emailBodies.get("emailPlainTextBody"));
            }
            m.sendMessage();
          }
        } else {
          if(formBean != null){
            try {
              HibernateUtil.delete(formBean);
View Full Code Here

      m.setToName(user.getFullName());
      m.setSubject(LanguageUtil.get(locale, "reset-password-email-subject"));
      m.setHTMLBody(body.toString());
      m.setFromName(company.getName());
      m.setFromEmail(company.getEmailAddress());
      m.sendMessage();
    }
    catch (Exception ioe) {
      throw new SystemException(ioe);
    }
  }
View Full Code Here

    mailer.setToEmail(toEmail);
    mailer.setSubject(subject);
    mailer.setFromName(fromName);
    mailer.setFromEmail(fromEmail);
    mailer.setHTMLBody(emailBody);
    mailer.sendMessage();
  }
}
View Full Code Here

    else {
      //personalize
      Mailer.setTextBody(finalMessageStr);
    }

    boolean sent = Mailer.sendMessage();
    if (!sent) {

      recipient.setLastResult(500);
      recipient.setLastMessage(Mailer.getErrorMessage());
    }
View Full Code Here

        if (isHTML) {
          mail.setHTMLAndTextBody(emailText);
        } else {
          mail.setTextBody(emailText);
        }
        mail.sendMessage();
      }
    } catch (Exception e) {
      throw new DotWorkflowException("Exception ocurred trying to deliver emails for workflow " + e.getMessage());
    }
View Full Code Here

      mailer.setSubject(subject);
      mailer.setFromEmail(fromEmail);
      mailer.setFromName(fromName);

      mailer.addAttachment(attachment);
      mailer.sendMessage();
    }
    catch(Exception ex)
    {
      String message = ex.toString();
      Logger.debug(WebFormFactory.class, message);
View Full Code Here

                if (isHTML) {
                    mail.setHTMLAndTextBody(emailText);
                } else {
                    mail.setTextBody(emailText);
                }
                mail.sendMessage();
            }
        } catch (Exception e) {
            throw new DotWorkflowException("Exception ocurred trying to deliver emails for workflow " + e.getMessage());
        }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.