Hello,
todays post is about a very simple to use php helper class for mail sending.
The class is easy to use and can serve the purpose of multiple mail sending using one function call.
Remember you need to do all your validation yourself... until I build the php helper class for all possible sorts of required validations.
Simply get the mail class from http://nasaralla.googlecode.com/files/mail.php
________________________________________
//include the mail class in your code
include("mail.php");
//instantiate the Mailer class with the
$mail = new Mailer('receiver@example.com','sender@example.com','subject','message');
//or you can also instanciate with cc and Bcc
$mail = new Mailer('receiver@example.com','sender@example.com','subject','message','cc@example.com','bcc@example.com');
//then simple call the send mail function
$mail->send_mail();
//you can also send mail to a list of people
$mail = new Mailer('','sender@example.com','subject','message');
$array = new array('receiver1@example.com','receiver2@example.com','receiver3@example.com');
$mail->send_mail_list($array);
________________________________________
Blog Archive
Friday, 22 January 2010
PHP mail helper class
Labels:
helper,
php,
php class,
php helper,
php mail,
php mail class,
php mail function
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment