* **************************************************************************** * SmtpMailer : Module using PHPMailer to send e-mail through the SMTP protocol * **************************************************************************** * Maintainer Contact ----------------------------------------------- Renaud Merle (nickname on SS forum is "rndmerle") e-mail : rndmerle ~at~ gmail ~dot~ com Contributors ----------------------------------------------- Dean Rather (github.com/deanrather) Requirements ----------------------------------------------- SilverStripe 2.3.0+ Installation Instructions ----------------------------------------------- 1/ Extract the smtpmailer folder into the top level of your site 2/ Without any configuration, SmtpMailer is going to connect to the local mail server on localhost, without authentication 2/ Configure to your liking : edit mysite/_config.php and set those constants (here using fictive values) : define('SMTPMAILER_SMTP_SERVER_ADDRESS', 'smtp.gmail.com'); # SMTP server address define('SMTPMAILER_DO_AUTHENTICATE', true); # Turn on SMTP server authentication. Set to false for an anonymous connection define('SMTPMAILER_USERNAME', 'acme@gmail.com'); # SMTP server username, if SMTPAUTH == true define('SMTPMAILER_PASSWORD', 'pass'); # SMTP server password, if SMTPAUTH == true # Optional : define('SMTPMAILER_CHARSET_ENCODING', 'utf-8'); # E-mails characters encoding, e.g. : 'utf-8' or 'iso-8859-1' define('SMTPMAILER_USE_SECURE_CONNECTION', 'ssl'); # SMTP encryption method : Set to '' or 'tls' or 'ssl' define('SMTPMAILER_SMTP_SERVER_PORT', 465); # SMTP server port. Set to 25 if no encryption or tls. Set to 465 if ssl define('SMTPMAILER_DEBUG_MESSAGING_LEVEL', 0); # Print debugging informations. 0 = no debuging, 1 = print errors, 2 = print errors and messages, 4 = print full activity define('SMTPMAILER_LANGUAGE_OF_MESSAGES', 'fr'); # Language for messages. Look into code/vendor/language for available languages 3/ If you're using SS_LogEmailWriter and want it to work with the SMTP protocol, you should use the extended class instead by adding this to your mysite/_config.php : SS_Log::add_writer( new SMTP_LogEmailWriter('your email here'), SS_Log::ERR ); 4/ If you want to fall back to the classic Mailer without uninstalling SmtpMailer : edit smtpmailer/_config.php and comment out the "set_mailer" line.