WordPress.org

Ready to get started?Download WordPress

Forums

WP Mail SMTP
Fatal error: Call to undefined function wp_mail() (1 post)

  1. gary_ap
    Member
    Posted 1 year ago #

    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/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic