Page 1 of 1

[SOLVED] swiftmailer and phplist

Posted: Fri Feb 23, 2007 2:27 pm
by momotiki
The Ninja Space Goat | Please use

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]


Hello everyone. I use google for your domain for my domain's email, but would like to set up phplist to send out periodic newsletters. I'm also fairly new to the whole php thing. 

From my understanding, phplist is built to use php_mail, which doesn't support TLS and thus will not work with gmail. Anyone know what I will need to do to configure phplist to use swiftmailer instead? Is it as simple as calling swiftmail in the config file instead of php mailer? I'm assuming it's not that easy. Anyway, here is a copy of the relevant code from the phplist config file. Any experienced users of phplist out there? I also asked this question on the phplist forum.

Code: Select all

#If you want to use the PHPMailer class from phpmailer.sourceforge.net, set the following
# to 1. If you tend to send out html emails, it is recommended to do so.
define("PHPMAILER",1);
# To use a SMTP please give your server hostname here, leave it blank to use the standard
# PHP mail() command.
define("PHPMAILERHOST",'smtp.gmail.com');
# if you want to use smtp authentication when sending the email uncomment the following
# two lines and set the username and password to be the correct ones
$phpmailer_smtpuser = 'newsletter@mydomain.org';
$phpmailer_smtppassword = 'mypassword';
Thanks in advance!


The Ninja Space Goat | Please use

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]

Posted: Fri Feb 23, 2007 5:32 pm
by Chris Corbyn
I haven't looked at phplist sorry. I'd offer to take some time to look at it, but I feel it's best put their own developers that they move to Swift as opposed to having someone else "patch" the code.

It's possible to make a wrapper/adapter class to make swift act like PHPMailer, but due to reasons beyond Swift's control (i.e. the poor OO interface of PHPMailer) it will probably use just as much memory and take just as much time to compute.

Is your project open-source? If you would be willing to agree to a NDA I'd provide you with a patch for PHPMailer. I ask mention NDA only to prevent supporting a dead project over the top of my own.

possible solution

Posted: Sat Feb 24, 2007 1:19 am
by momotiki
I found this blog post that has a config of phpmailer that should work with gmail. Hopefully this will work. Will post with how it turns out. Sorry the solution probably won't involve swiftmailer, which seems superior in every way to php_mailer. =)

http://www.vulgarisoip.com/?p=17