a good class for php mail with attachment

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
PHPycho
Forum Contributor
Posts: 336
Joined: Fri Jan 06, 2006 12:37 pm

a good class for php mail with attachment

Post by PHPycho »

can anybody jot down the good class for php
that has a simple message field, subject,email, and attachemnet fields..
Thanks in advance...
User avatar
Luke
The Ninja Space Mod
Posts: 6424
Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA

Post by Luke »

well there is not going to be any one class that will include the form as well as send the mail because if one class did all that, it would not be oop. It would be spaghetti crap code. What I will suggest is that you build a form (standard html), post it to a php page, grab the $_POST vars, validate, and then use swiftmailer to send the email w/attachment. PHP and Swiftmailer both have excellent documentation and we here at devnet support both. If you have any questions, first check here, then here, then here, and then if that fails, ask in this thread.

Put together at least SOME code and I'll even help you with it. :D
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Re: a good class for php mail with attachment

Post by RobertGonzalez »

PHPycho wrote:can anybody jot down the good class for php
that has a simple message field, subject,email, and attachemnet fields..
Thanks in advance...
No. But we can tell you to use Swiftmailer as your mailing application.
Post Reply