", $message); require_once('/home/bateworldcom/public_html/mailer/class.phpmailer.php'); //include("class.smtp.php"); // optional, gets called from within class.phpmailer.php if not already loaded $mail = new PHPMailer(true); // the true param means it will throw exceptions on errors, which we need to catch $mail->IsSMTP(); // telling the class to use SMTP $mail = new PHPMailer(); $mail->IsSMTP(); // telling the class to use SMTP $mail->Host = "b8world.com"; // SMTP server $mail->SMTPAuth = true; // authentication enabled //$mail->SMTPSecure = 'ssl'; $mail->Port = 587; //$mail->SMTPSecure = 'ssl'; // secure transfer enabled REQUIRED for GMail $mail->Username = "happybirthday@b8world.com"; // SMTP account username $mail->Password = "y2sWJ*#h8)xG"; // SMTP account password //$mail->From = "mailservices@b8world.com"; $mail->SetFrom('happybirthday@b8world.com', 'Bateworld'); $mail->AddReplyTo('happybirthday@b8world.com', 'Bateworld'); $mail->AddAddress('porembaphilip@gmail.com'); $mail->Subject = 'Test of bateworld birthday eamil'; //$mail->AltBody = 'To view the message, please use an HTML compatible email viewer!'; // optional - MsgHTML will create an alternate automatically $mail->MsgHTML('Hello, this is the test email'); //$mail->AddAttachment('mailer/images/phpmailer.gif'); // attachment //$mail->AddAttachment('mailer/images/phpmailer_mini.gif'); // attachment $mail->Send(); //echo "Message Sent OK

\n"; //echo "Message Sent OK

\n"; } catch (phpmailerException $e) { //mail("porembaphilip@gmail.com", "MAIL ERROR", $e->errorMessage()); echo $e->errorMessage(); //Pretty error messages from PHPMailer } catch (Exception $e) { echo $e->getMessage(); //Boring error messages from anything else! //mail("porembaphilip@gmail.com", "MAIL ERROR", $e->getMessage()); } echo "check"; //mail("porembaphilip@gmail.com", "MAIL ERROR", "testing message"); ?>