• Resolved nkoltys

    (@nkoltys)


    Just starting using free version Post to Email. I suspect this may not be a Jetpack issue. But maybe you can help. The inbound post appears in our WP site with Published status as designed. We have PostSMTP job that looks for New Published to set an alert to our community. That is not being triggered. HOWEVER, if we go back to the Post, change status to say Pending then Published, the PostSMTP works. It’s almost as if the Jetpack generated “Published” status is not being set or recognized. Thoughts?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Support Mehdi (a11n)

    (@muffinpeace)

    Hi @nkoltys

    I see you mention having issues with the PostSMTP job not working expectedly with the Published post status; however, is there anything that made you suspect Jetpack? Can you also explain what you are referring to as Jetpack-generated “Published” status?

    Thread Starter nkoltys

    (@nkoltys)

    it continues to be a challenge.  When we manually create a Post in WordPress to the Published status, the Better Notifications picks it up and sends a notification as expected. Jetpack’s post to email creation of a Post with a Published status to WordPress works fine.  However, the firing of the notification doesn’t happen.  It’s as if Jetpack is not publishing a fully-formed Post record — perhaps without a user being defined (see below) in the Jetpack-created record.

     It may have something to do with Jetpack’s use of a Webhook. See the link below, same problem different user two years ago as reported in the Notifications app.

    https://wordpress.org/support/topic/no-notification-when-post-is-created-via-webhook/

    Thread Starter nkoltys

    (@nkoltys)

    could it be a caching issue or both

    $fire_after_hooks bool Optional

    Whether to fire the after insert hooks.

    Default: true

    Thread Starter nkoltys

    (@nkoltys)

    Can somebody look into this?

    Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic 🚀

    I looked into this a bit, and I’m not sure there is much we can do about this. When you use Jetpack’s Post by Email, the posts end up being created via a wp_insert_post where we do not overwrite that third value you mention above.

    If your PostSMTP job currently hooks into wp_insert_post, it may be worth running some tests with a different approach that is triggered later, to catch all post creations on your site. You could for example try to use the save_post_post hook instead:

    https://developer.wordpress.org/reference/hooks/save_post_post-post_type/

    Another option would be to extend the job to also hook into an action that is set in Jetpack whenever a post is created via the API: rest_api_inserted_post. You can find documentation about that hook here:

    https://developer.wordpress.org/reference/hooks/save_post_post-post_type/

    That would allow you to support posts created via Jetpack’s Post By Email without changing the current logic for posts that are manually created on your site.

    I hope this helps.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Post to WP: Published Status Working BUT …’ is closed to new replies.