Skip to:
Content
Pages
Categories
Search
Top
Bottom

Force all users to be subscribed to all topics

Viewing 8 replies - 1 through 8 (of 8 total)
  • There is a plugin that makes the Subscribe to Replies option checked by default. Would that work for you? It would only apply when users posted a reply though.


    NewSha
    Participant

    @newsha

    Thanks for your reply! Unfortunately users should receive email notifications even if they didn’t post a reply…

    There’s not a plugin for that as far as I know, sorry.


    John James Jacoby
    Keymaster

    @johnjamesjacoby

    Unfortunately, this won’t scale very well. Notifications and Favorites are stored in a serialized array is usermeta, and keeping track of every topic will eventually slow things down significantly.

    Instead, I’d filter `bbp_is_user_subscribed` and invert the results. That way you’re subscribed to all topics, and bbPress only stores the topics your users are not subscribed to.

    Make this into a plugin:

    `function invert_subscribe( $is_subscribed ) {
    return ! $is_subscribed;
    }
    add_filter( ‘bbp_is_user_subscribed’, ‘invert_subscribe’ );`


    NewSha
    Participant

    @newsha

    Thank you for your reply John!
    Excuse me my stupidity, but I don’t really get how to implement this code.
    Could you explain to which file in “wp-content/plugins/bbpress” should I add this piece of code?
    Should I download any extra plugins?
    Thanks!

    That shouldn’t go in bbPress. Never modify the plugin, everything gets lost when you update.

    It should go in your theme’s functions.php file.


    NewSha
    Participant

    @newsha

    Thank you for your reply!
    I’ve added

    function invert_subscribe( $is_subscribed ) {
    return ! $is_subscribed;
    }
    add_filter( ‘bbp_is_user_subscribed’, ‘invert_subscribe’ );
    

    to my functions.php file, but it doesn’t seem to work…
    My users still don’t get email notifications for some reason.
    Any suggestions?


    NewSha
    Participant

    @newsha

    Yaay! I found the solution: this plugin https://wordpress.org/extend/plugins/bbpress-notify/

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