Advertisement
Guest User

Untitled

a guest
Oct 11th, 2016
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.94 KB | None | 0 0
  1. public function sendActivation($name, $user, $pass, $activationKey)
  2. {
  3. $to = $user;
  4. $subject = 'Account Activation';
  5. $headers = "From: noreply@domain.tldrn";
  6. $headers .= "MIME-Version: 1.0rn";
  7. $headers .= "Content-Type: text/html; charset=UTF-8rn";
  8. $message = "<div id='mail' style='height: auto; width: 500px;background-color: #DDDDDD; font-family: Tahoma, Arial, sans-serif;'>
  9. <p>Hello dear $name and thanks for your choise!</p>
  10. <p>Your details:</p>
  11. <p>Username: $user</p>
  12. <p>Password: $pass</p>
  13. <p><br /></p>
  14. <p>Here there is an activation link. Please click on it to activate your account.
  15. If you don't activate your account in next 24 hours, your account will be deleted automaticly.</p>
  16. <p><a href='" . BASE_PATH. "/register/activation/$user/$activationKey'>Activate Your Account!</a></p>
  17. </div>";
  18.  
  19. if (mail($to, $subject, $message, $headers))
  20. return true;
  21. return false;
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement