Adjust from name and email for wp_mail()


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1.  
  2.  
  3.  
  4. 1 <?php
  5. 2 function mail_from() {
  6. 3 $emailaddress = '[email protected]';
  7. 4 return $emailaddress;
  8. 5 }
  9. 6
  10. 7 function mail_from_name() {
  11. 8 $sendername = "1stWebDesigner.com - Dainis";
  12. 9 return $sendername;
  13. 10 }
  14. 11
  15. 12 add_filter('wp_mail_from','mail_from');
  16. 13 add_filter('wp_mail_from_name','mail_from_name');
  17. 14 ?>

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.