Support » Plugin: WP Mail SMTP by WPForms » [Plugin: WP Mail SMTP] Fatal error: Call to undefined function wp_mail()

  • gary_ap

    (@gary_ap)


    Hi, I’ve just installed the wp_mail_smtp plugin. The settings are ok and I’m able to send out a test e-mail successfully.

    When configuring my php file to use wp_mail() it gives an error:
    Fatal error: Call to undefined function wp_mail() in /home/path to .php

    the line of code is:
    wp_mail($address,”Subject here”,$txt,”From: subscriptions@emailaddress.co.uk“);

    As my php is called outside of wordpress do I need to include any wordpress code?

    Previously was working with mail() but would like to change to use smtp

    Any help much appreciated

    Thanks in advance
    Gary

    http://wordpress.org/extend/plugins/wp-mail-smtp/

  • The topic ‘[Plugin: WP Mail SMTP] Fatal error: Call to undefined function wp_mail()’ is closed to new replies.