• Resolved Duke

    (@dukessa)


    Hello,

    I’m using the post expirator (but I replaced the main plugin file with this one, that adds Pending as status option), so I can set a date and make posts change status through cron.

    The expiration (change of status to Pending) works perfectly, but no notification is sent from BNFW.

    The test notification email sends fine, so it’s most likely that since the save_post hook is not used in this case, the notification simply doesnt know the post status has changed.

    As you can see from the Gist, on line 478, the function cron fires is wp_update_post.
    Do you think you could hook into that too to detect post status change?

    https://wordpress.org/plugins/bnfw/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author bnfw

    (@voltronik)

    Hi Duke,
    Thanks for your message.

    To clarify, are posts transitioning from published to pending or draft to pending or something else?

    Thanks,
    Jack

    Thread Starter Duke

    (@dukessa)

    Yes, it goes from published to pending usually.
    However, it could also go from draft to pending, in some cases, I suppose.

    Plugin Author bnfw

    (@voltronik)

    Hi Duke,
    Am investigating how to do this.

    I’ve been pondering a custom status-to-status add-on for a bit now and feel this may work well. It would allow you to choose an start and end status for a post / page / custom post type to trigger a notification.

    Would that be of any use?

    Jack

    Thread Starter Duke

    (@dukessa)

    The expiration is a little more than just a post status change sometimes (opional change of category as well, change of post type, or just trash when expired etc).
    If your add-on includes all possible options then it might be interesting.

    For the time being, any advice?

    Plugin Author bnfw

    (@voltronik)

    Hi Duke,
    Sounds interesting. Could you give examples of each of the scenarios above for clarification on requirements?

    In the meantime, the only thing I can suggest would be to modify the core plugin to achieve what you’re after. I think a good place to start would be line 128 of bnfw.php.

    Thanks,
    Jack

    Plugin Author bnfw

    (@voltronik)

    Closing due to inactivity. If you need further help with this, please feel free to re-open this thread.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘No email sent on post status cron change (to pending)’ is closed to new replies.