• Resolved cinderalla

    (@cinderalla)


    We use Post SMTP Mailer/Email to send all WP generated emails. However, I need to send a notification email when a post is updated and not sure how to do this in functions. I’ve tried to do it using wp_mail from the save_post hook with no success.

    Any ideas how I could accomplish this?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Try this

    $postmanWpMail = new PostmanWpMail ();
    $result = $postmanWpMail->send ( $to, $subject, $message, $headers, $attachments );

    The params are the same as wp_mail

    Thread Starter cinderalla

    (@cinderalla)

    @yehudah Thanks for your suggestion. I wasn’t able to get it to work using “new PostmanWpMail()”. However, it turns out that wp_mail does work. I was able to get the notifications to send via Post SMTP with just wp_mail() in my function.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Is it possible to send an email by PHP code with your plugin?’ is closed to new replies.