wp_mail() is a wrapper for PHPMailer which is a wrapper for PHP’s mail() function.

learn more… | top users | synonyms

0
votes
1answer
35 views

Remove from “Wordpress” when reciving email (Should I remove filter?)

I am getting "Wordpress" when I sending my email using wp_mail. So to remove "Wordpress" from my e-mail I am using filter like so: //Remove "Wordpress" when receiving email function ...
0
votes
2answers
255 views

wp_mail attachment not working

Hello I am trying to send mail with some attachment using with wordpress wp_mail functionality but I am not getting attachment in my mailbox. Can you please check my bellow code and guide me where I ...
0
votes
2answers
596 views

wp_mail recipient array not sending?

I am using wp_mail to send an email to multiple recipients. my mail function looks like this: wp_mail($group_emails, 'my subject', 'my message', $headers); $group_emails is an array of email ...
0
votes
1answer
89 views

How can I format email notification after registration?

I saw already this answer. And it helped me to make unique mail. It's great. But how to format some text using HTML? For example to work with tags <b> <i> <font color="red"> ...
0
votes
1answer
680 views

wp_mail strips out the link url from the anchor tag in mail content

When the email content contains a link with url like: mobileappname://accesstoken#w34rdgtsrt5v6m, <a href="mobileappname://accesstoken#w34rdgtsrt5v6m">Click</a> wp_mail function removing ...
0
votes
1answer
265 views

Send email for confirmation during user registration

I am very new to WP.How does a confirmation mail is sent during user registration.Is there any services being worked out here. is this a free service using php for any plugin.
0
votes
1answer
169 views

How to get post meta in functions?

I set an email button in functions php. The email is sent when clicking on a front-end update post button. The problem is: the email is sent but I can't get the post title to appear in the post. I ...
0
votes
1answer
182 views

Sends out email to admin with post author

Hello i'm using this : add_action('publish_post', 'send_admin_email'); function send_admin_email($post_id){ $to = 'admin@email.here'; $subject = 'subject'; $message = "Here is ...
0
votes
1answer
590 views

Images in wp_mail not showing

I created a plugin that sends an email: $subject = 'New comment - '.$post_title; ob_start(); include(SUBSCRIBE_USER_BASE_DIR . '/email/message.php'); $message = ob_get_clean(); ...
0
votes
1answer
1k views

why is wp_new_user_notification not working?

i dont like to use a plugin so i made use of user registration custom signup page and its not sending any emails:( at first everything is working then i added some functions to change the from and the ...
0
votes
1answer
314 views

Conditional wp_mail statement on post

I am currently posting from the front end using a similar model as http://voodoopress.com/2011/03/review-of-posting-from-front-end-form/. I want to send an email to certain addresses based on the ...
0
votes
0answers
8 views

wp_mail function not dispatching emails from plugin

I am working on a plugin that needs to dispatch an email to the user after they submit a form. I have tried quite a few different things but none of them are working. I have also tested from my local ...
0
votes
0answers
15 views

How to send mail from 7 days before to an expiry date?

My task is to send mail to all users before seven days to an expiry date. I have Expiry date like: $expiry_date = date('Y-m-d H:i:s', $new_date); // 1/08/2015 //7 days before $seven_days_before = ...
0
votes
0answers
28 views

Different Name and Email for wp_mail_from and wp_mail_from_name

I want to make the email and Name dynamic.Everything works fine.But I can't able to get the name and email for each doctors.I have attached my code which I have tried.please help Thanks in Advance. ...
0
votes
0answers
24 views

wp_mail recipient

I am new at this and seeking help, I'm really need a light at the end of the tunnel, so if you can help me, please do it! I will be very grateful! The question is, what do I do to when someone fills ...
0
votes
1answer
33 views

Hook into admin_notices after sending mail

In my (admin) plugin I want to display a message using admin_notices action on successful sending of mail. Currently it is not displaying. I know this has something to do with the order of events, but ...
0
votes
0answers
17 views

Email post content

I have this function in functions.php to send an email when a new post is published. How can I add the content of the post as the message in the email. function authorNotification($post_id) { ...
0
votes
2answers
52 views

Send email from Wordpress

What's the best way to send a email from Wordpress after a certain action. I'm working on a site where users can submit ideas and then other users can comment on them. I would like to send emails to ...
0
votes
0answers
42 views

How can I replace Email addresses with BitMessage Addresses througout wordpress?

BitMessage (bitmessage.org) is a peer-to-peer email system kind of based on BitTorrent. By itself, this software and its' messages are not compatible with email, so in order to send an email to a ...
0
votes
1answer
79 views

html mail sended with wp_mail shows plain

I have a invoice.html that i want to send i use the following function to replace some things in the html foreach($variables as $key => $value){ $template = str_replace('{{ '.$key.' }}', ...
0
votes
1answer
66 views

Wp_Mail and Contact Form 7

I have a problem. I've used add_filter('wp_mail_from', 'new_mail_from'); add_filter('wp_mail_from_name', 'new_mail_from_name'); function new_mail_from($old) { return 'contact@mysite.hk'; } ...
0
votes
0answers
37 views

wp_trash_post retrashes already trashed comments?

I have a few mail- and update_user_meta functions that fires when a post, comment or child comment gets thrashed. So when I trash a comment with trash_comment, a mail get sent to the author: "Hey, ...
0
votes
1answer
66 views

Add a hook to wp_mail() to track Google Analytics Event

I hope you'll be able to help me on this one: I'm trying to trigger a GA event for every email sent via a Wordpress site. My idea was to add the following code to my child theme's functions.php ...
0
votes
1answer
483 views

Custom Contact Form Not Sending (but not giving error)

hope things are going well. I'm attempting to add a custom contact form to a section of home page. I came across a custom contact form at https://gist.github.com/hansspiess/6815875. I implemented the ...
0
votes
1answer
190 views

Only single mail function is working from double mail functions one after another on wordpress

I am having a html form in my wordpress page and i have call action on my form. The file which is calling an action is saved in the root of wordpress directory. sending-mail.php I have two mail ...
0
votes
1answer
111 views

send email to all registered users when post expires

I have a function which, when a post is published inside a CPT after three days the page is redirected to another URL/PERMALINK. This is the code: add_action('template_redirect', ...
0
votes
2answers
845 views

wp_mail() is not working on server

i am breaking my head from last 1 hour but not getting any idea that what's going wrong with my code... i am developing my own plugin and i am using wp_mail() function for sending mail in that but ...
0
votes
1answer
96 views

upload file with front-end submission and forward the data in an email

I have an email set up using wp_mail that forwards my front-end submission data as well as posting it to the dashboard. The part that I am having trouble with is forwarding the attachment file with ...
0
votes
0answers
291 views

Problem using wp_mail function

I have a form whose message is composed from multiple input fields when submitted. I got this form working as simple php document but when I'm trying to use the form within a wordpress page it doesn't ...
0
votes
1answer
608 views

Reset Password - change from name and email address

When the password reset goes out, the name is 'WordPress' and the from address is wordpress@domain.com. I need to change these to the company name. I'm running WordPress 3.8 multisite and have done ...
0
votes
0answers
30 views

how to invoke mail with additional parameters

My mailserver doesn't send me WordPress notifications. My hoster says that to have the php function mail(,,,,) working I need to set the fifth parameter (additional parameter) equal to -f ...
0
votes
0answers
213 views

Using wp_cron with wp_mail to send bulk email

I am working on a custom plugin to send recurring invoices on the 1st of every month. So far, the plugin is working pretty well. It creates new invoices for each user based on their order and does ...
0
votes
1answer
681 views

File upload from front-end form (as attachment) not working

I have a front-end form that is supposed to allow the user to upload a CV which is then sent along with the rest of the form as an attachment. To do so I have used wp_handle_upload() like so: if ...
0
votes
1answer
208 views

WooCommerce wp_mail attachment not working dynamically

I have edited function send() to attach the file in woo commerce plugin when, I am use the attachment file path statically it work's but when, I put it on dynamically attachment source not able send ...
0
votes
0answers
264 views

Email attachment not working using wp_mail function

I am trying to send email with attachment but, I am not getting any attachment but I am getting the email bellow is the function ,I have used in function.php and I am trying to attach a zip file fro ...
0
votes
0answers
287 views

How to add attachment in woo commerce send mail function

I am using woo-commerce plugin. After the checkout process, I am sending a mail to customer, it's working good but also, I want to attach the product image into the mail. I am not getting any idea how ...
0
votes
1answer
120 views

get_post_meta is always empty when I use wp_mail

I made this action hook which will send an email to the users every time a new post in the custom post type "events" is made. function email_members($post_id) { global $wpdb; $usersarray = ...
0
votes
0answers
12 views

Mail sending randomly fails

I'm having a troublesome problem here. I set up a event subscription plugin that should send a confirmation mail at the end of the subcription process. Here's the code: wp_mail( $data['email'], ...
0
votes
0answers
308 views

wp_insert_user email confirmation

I'm creating a new user once they leave a comment, i am doing this with wp_insert_user function create_comment_user($comment_ID){ global $wpdb; $comment = get_comment($comment_ID, ARRAY_A); ...
0
votes
3answers
577 views

Not sure how to debug: Send specific users an email when posts are published

I've got the following code, which is supposed to run when a new post is published for the first time, check if a custom field 'specific_users' has data (this uses Advanced Custom Fields), and if so, ...
0
votes
1answer
700 views

Check to check if wp_mail is working properly?

I'm trying to use wp_mail (testing on local machine) but no mail is received. The php.ini has smtp_port = 25 set and the php mail() is working so far. how can I check if wp_mail is working what can ...
0
votes
0answers
169 views

Verify Registration email on local host windows 7 xampp

I am very new to word press development. I have set up xampp and successfully installed wordpress on my localhost with my admin account. I need to create a registration for the users to register in my ...
0
votes
0answers
77 views

Wordpress email notification using address with plus sign

So I've managed to change mail_from used by WP to send e.g. new comment notifications by adding filters like that: add_filter('wp_mail_from_name', 'get_name'); add_filter('wp_mail_from', ...
0
votes
1answer
978 views

wp_mail: An array as $to - multiple emails or single email with all the email ids in it?

If I will use an array of email IDs for $to parameter of wp_mail function, will it send different emails to all those email ids or will send one email with all the email ids as 'to'?
0
votes
1answer
224 views

wp_mail - using a custom field value

Can this work? I want to send a email when a post is published to the recipient, that is called in custom field. EDIT I changed the code to another example I found. function ...
0
votes
2answers
3k views

Using wp_mail in functions.php

I have set up a simple mailer before I get the full implementation sorted. I've tried a few email addresses but am not receiving them even though it returns 'true'. I'm using wp_ajax as well if that ...
0
votes
1answer
464 views

wp_mail_from not changing from address

I wish to use the wp_mail_from hook to change the from email address submitted through a form which sends an invitation to a friend by email (I am writing my own plugin to do this). I am using the ...
0
votes
1answer
878 views

wp_mail is sending two emails when used after retrieving session data

I'm using the wp_mail function to send emails in WordPress. Before I run the function, I retrieve a heap of data from a session and some others from a form that was just submitted. For example: ...
0
votes
1answer
384 views

send bulk emails without timeout

I am developing a plugin that sends emails out to users. I am having difficulty in finding the most performance enhanced way to send these emails out and prevent a server timeout. In other words, I ...
-3
votes
1answer
145 views

Not receiving mail using wordpress function

I'm not receiving emails when using the following function. Is there another method that works or that I can test? <?php $data = ob_get_clean(); ...