• Installed plugin WP-Mail-SMTP Version 0.9.1 (“Reconfigures the wp_mail() function to use SMTP instead of mail() and creates an options page to manage the settings”).

    I’m using smtp.gmail.com with the recommended settings, and the plugin is able to send a test email from wp-admin. That’s fine, but I’m having trouble translating that into where the email is actually being sent in the PHP program, which is called formprocessor2.php. I’ve seen the general recommendations to change mail() to wp_mail(), but I don’t really understand the specifics of how to do that. I did try changing the mail() command in formprocessor2.php to wp_mail() and got this error:
    Call to undefined function wp_mail() in C:\wamp\www\testsite\rosterform\formprocessor2.php on line 86

    I do know the mail() command in the PHP program doesn’t seem to make use of the plugin (it just hangs when sending an email). The instructions say something about, “If you’re using plugins to send email…” but I’m not really using another plugin, just the mail() command, and I can’t figure out what I need to do to get it to use the plugin.

  • The topic ‘[Plugin: WP Mail SMTP] – Getting to Work in PHP’ is closed to new replies.