Guest User

Untitled

a guest
Sep 15th, 2018
163
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.11 KB | None | 0 0
  1. PHPMailer sending e-mails with the warning: This message may not have been sent by: foo@gmail.com Learn more Report phishing
  2. //mail funtions
  3. require("mailer/class.phpmailer.php");
  4. require("mailer/class.smtp.php");
  5. require("mailer/class.pop3.php");
  6.  
  7. $mail = new PHPMailer();
  8. $mail->IsSMTP();
  9. $mail->Host = "relay-hosting.secureserver.net";
  10. $mail->Port = 25;
  11. $mail->IsHTML(true);
  12. $mail->Username = "foo@gmail.com"; // SMTP username
  13. $mail->Password = "pass"; // SMTP password
  14.  
  15. $mail->From = "foo@gmail.com";
  16. $mail->FromName = "FOO";
  17. $mail->AddAddress("fOO@gmail.com", "WIDB");
  18. $mail->AddReplyTo("foo@gmail.com");
  19. //$mail->AddAddress("foo@gmail.com"); // name is optional
  20.  
  21. $mail->WordWrap = 50; // set word wrap to 50 characters
  22. //$mail->AddAttachment("/var/tmp/file.tar.gz"); // add attachments
  23. //$mail->AddAttachment("/tmp/image.jpg", "new.jpg"); // optional name
  24. $mail->IsHTML(true); // set email format to HTML
  25.  
  26. $mail->Subject = 'Foo - Transaction Receipt';
  27. $mail->Body = $message;
  28. $mail->AltBody = "nothing";
  29.  
  30. //send mail
  31. $mail->Send();
Add Comment
Please, Sign In to add comment