Advertisement
Guest User

Untitled

a guest
Dec 20th, 2018
156
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. $mail = new PHPMailer();
  2.  
  3. $mail->IsSMTP(); // telling the class to use SMTP
  4. $mail->Host = "192.168.30.8"; // SMTP server
  5. $mail->SMTPAuth = true;
  6. $mail->Username = "FR\Administrator";
  7. $mail->Password = "P@ss-word";
  8.  
  9. $mail->SetLanguage("en", DIR_3RDPARTY."/phpmailer/language/");
  10.  
  11. $mail->From = "aangifte@fr.ism";
  12. $mail->FromName = "FR.ism";
  13. $mail->AddAddress("aangifte@fr.ism");
  14.  
  15. $mail->Subject = "SMTP Test";
  16. $mail->Body = "Hello World";
  17.  
  18. if(!$mail->Send()) {
  19. echo 'Message was not sent.';
  20. echo 'Mailer error: ' . $mail->ErrorInfo;
  21. } else {
  22. echo "Sent";
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement