Skip to:
Content
Pages
Categories
Search
Top
Bottom

Users don't receive notifications for new topics created in admin


  • marcuswhit
    Participant

    @marcuswhit

    I have several users subscribed to a forum, and they all receive email notifications when a new topic is created in the regular way through the front end. However, if a user creates a topic for that forum via the admin area, they don’t receive notifications.

    Is this by design? I would have thought the behaviour should be the same regardless of how the topic is created.

Viewing 3 replies - 1 through 3 (of 3 total)

  • marcuswhit
    Participant

    @marcuswhit

    Hi, any ideas on this? Thanks.


    tharsheblows
    Participant

    @tharsheblows

    I think this is going to be less than helpful for you, I’m sorry.

    I’m not sure but it doesn’t look like / I can’t find where bbp_notify_forum_subscribers (the function that sends emails to subscribers) is hooked into the admin topic post save. What I mean is, you’re right, the subscriptions don’t seem to sent if you create a new topic in admin. (I could be completely wrong about this and just missed something though.)

    Anyway, I’m just going to write down where I would start if that is the case because I hope that I can come back to this in a bit or someone else will and otherwise I’ll forget (I’m off on holiday tomorrow). I would say to hook it into save_post but I’m not sure that you can do that because bbp_notify_forum_subscribers doesn’t check post type so would run on any post type save.

    So something like this: https://codex.wordpress.org/Plugin_API/Action_Reference/save_post#Custom_Post_Type:_.27book.27 I mean the write a function that checks for post type bit and call bbp_notify_forum_subscribers.

    And do the same thing with the reply post type, too (but with bbp_notify_subscribers).

    If this gets moved to trac, it would be easier to change those two functions to check for post type first thing and hook them both directly into save_post rather than the way above.

    Again, I might just be missing where it’s hooked in. I hope that I’m missing something obvious and it’s an easy fix! 🙂


    wpturk
    Participant

    @wpturk

    Changing and saving topics in backend deletes subscriptions too. How can I stop this behaviour?

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Skip to toolbar