Advertisement
Guest User

Untitled

a guest
Oct 29th, 2016
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. $email = new PHPMailer(true);
  2.  
  3. //Using SMTP
  4.  
  5. $email->IsSMTP();
  6. //$email->Host = "in-v3.mailjet.com";
  7. $email->Host = "aspmx.l.google.com";
  8. $email->SMTPDebug = 1;
  9. $email->SMTPAuth = true;
  10. $email->Host = "smtp.gmail.com";
  11. $email->Username = $mail;
  12. $email->Password = $pin;
  13. $email->SMTPSecure = "ssl";
  14. $email->Port = 25;
  15.  
  16. //Not using SMTP anymore
  17. try{
  18. $email->SetFrom (" victaliumbot@victalium.16mb.com", "Victalium");
  19. $email->Subject = "Account Activation";
  20. $email->AddAddress($mail, $user);
  21. $email->IsHTML(false);
  22.  
  23. $email->MsgHTML($mail_msg);
  24. $email->Send();
  25.  
  26. echo "Account created, details:<br>----------------------------------------------------<br>Username: $nick,
  27. <br>Email: $mail, <br>Password: $pin.<br>----------------------------------------------------<br> Please check the verification e-mail sent to activate it :)";
  28.  
  29. } catch (phpmailerException $e){
  30.  
  31. echo "Error during registering, sorry :(";
  32.  
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement