• Resolved Mike Bennett

    (@mike-bennett)


    I have set up a category and two subscribers for this category.

    When I use the form to create a post, the category appears in the dropdown list, however when I set the title, category and some text for the post and press Submit Post, no emails are sent to the subscribers.

    My programming knowledge is with Java not PHP so I may be way off, but looking through the plug-in files, it looks like the function st_send_mail should be fired when the post is published. I have added the line printf(‘st_send_email’); after the global lines but this messages does not appear in the debug.log file.

    Any ideas?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Mike Bennett

    (@mike-bennett)

    Further investigation and I am now sure the function is not run by the publish_post action. I have moved the relevant code to the functions.php in my child theme and the function does run, however at the time the function runs, the entry for the post/category has not been added to the wp_term_relationships table in the database and as a result no emails are sent out.

    If I visit the post in the admin screen, the category is flagged and pressing resend causes the mails to be sent.

    Would this be a timing issue because the code is running in the themes functions.php rather than a plugins php file?

    Plugin Author Dhara Shah

    (@dharashah)

    Hi Mike,

    Kindly contact us at info[at]sanskruti[dot]net if you are still facing this issue.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Email sender not fired’ is closed to new replies.