Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best PHP Mail class [closed]

Tags:

oop

php

email

class

I've been using php's mail function for years and decided it was finally time to make my code a bit more Object Oriented rather than writing out the code each time.

I was going to build my own mailer class but I figure there must be a ton of great classes out there already. I started looking and got a bit overwhelmed by the choice so I thought it was a good question to put to SO

Can anyone recommend their favourite/best php mail class?

I'm just using it to send plain text email right now but will be shortly switching to html formatted emails so something that can grow with me would be best.

Thanks

like image 315
salonMonsters Avatar asked Feb 03 '23 10:02

salonMonsters


1 Answers

We have been using PHPMailer for nearly a decade with no problems:

https://github.com/Synchro/PHPMailer

It has some nice features, such as good email validation (a harder problem to solve than it seems), and converting your HTML to human-readable plain text, with very nice ascii formatting for headers, tables, etc.

like image 76
Abhi Beckert Avatar answered Feb 05 '23 08:02

Abhi Beckert