Advertisement
Guest User

Untitled

a guest
Dec 7th, 2016
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.27 KB | None | 0 0
  1. <?php
  2. require 'mailer/PHPMailerAutoload.php';
  3.  
  4. $mail = new PHPMailer;
  5.  
  6. //$mail->SMTPDebug = 3; // Enable verbose debug output
  7.  
  8. $mail->isSMTP(); // Set mailer to use SMTP
  9. $mail->Host = 'in-v3.mailjet.com'; // Specify main and backup SMTP servers
  10. $mail->SMTPAuth = true; // Enable SMTP authentication
  11. $mail->Username = '428fed465f1bc58fc7a6dcfe042f01ff'; // SMTP username
  12. $mail->Password = '3eb7a25339430a472ae3c06efc7491d4'; // SMTP password
  13. $mail->SMTPSecure = 'tls'; // Enable TLS encryption, `ssl` also accepted
  14. $mail->Port = 587; // TCP port to connect to
  15.  
  16. $mail->setFrom('teukurevand@gmail.com', 'PUMA COMP');
  17. $mail->addAddress('thilmanrevanda@gmail.com'); // Add a recipient
  18. $mail->addReplyTo('pumacomputing@gmail.com', 'PUMA COMP');
  19.  
  20. $mail->isHTML(true); // Set email format to HTML
  21.  
  22. $mail->Subject = "PUMA COMP";
  23. $mail->Body = "<p>test</p>";
  24. $mail->AltBody = "test";
  25.  
  26. if(!$mail->send()) {
  27. echo 'Message could not be sent.';
  28. echo 'Mailer Error: ' . $mail->ErrorInfo;
  29. } else {
  30. echo 'Message has been sent';
  31. }
  32. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement