Skip to:
Content
Pages
Categories
Search
Top
Bottom

Uncheck "Notify me of follow-up replies via email" by default.


  • JeremyPark123999
    Participant

    @jeremypark123999

    Hi, I have been trying to figure out how to have the “Notify me of follow-up replies via email” button unchecked by default, as I have topics in my forum, such as forum games, that will not require follow-ups. I have found lots of threads on how to have it checked by default (for an older version of bbpress I assume) but none on how to do the opposite. As I am still quite new to PHP, I have been unable to complete this so far. Any help would be great.

    http://www.tumbleweed.minecraftus.com

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

  • Robin W
    Moderator

    @robin-w

    by default it is unchecked – is your site the other way round?


    JeremyPark123999
    Participant

    @jeremypark123999

    Yes, although I am not sure why.


    Robin W
    Moderator

    @robin-w

    by default it is unchecked – is your site the other way round?

    Yes, although I am not sure why.

    I presume you mean checked by default?


    JeremyPark123999
    Participant

    @jeremypark123999

    Yes, I am not sure if I have another plugin that might be affecting it, but it is currently checked by default.


    Robin W
    Moderator

    @robin-w

    Another plugin sounds possible – try disabling them one at a time and see if without one it works ok.

    Otherwise, you could try adding this to your functions file

    function pw_bbp_auto_checK_subscribe( $checked, $topic_subscribed  ) {
    
        if( $topic_subscribed == 0 )
            $topic_subscribed = true;
    
        return checked( $topic_subscribed, true, false );
    }
    add_filter( 'bbp_get_form_topic_subscribed', 'pw_bbp_auto_checK_subscribe', 10, 2 );

    That sets it to checked, so presumably if you changed line

    $topic_subscribed = true;to

    $topic_subscribed = false;

    it should uncheck it

    Give it a try


    JeremyPark123999
    Participant

    @jeremypark123999

    I disabled all of the plugins except bbpress, and I also tried adding that code to bbpress/includes/common/functions.php and also to my themes functions.php . Maybe I am doing something wrong though, is there perhaps a way to hide the check box? That would work just as well for me.


    Robin W
    Moderator

    @robin-w

    tried to sign up for an account so that I can see this, but the signup worked, but login didn’t. Maybe you need to authorise?


    JeremyPark123999
    Participant

    @jeremypark123999

    I am ashamed to say, that it seems that I found a solution that was staring me in the face in the settings panel for bbpress. I simply disabled the “Allow users to subscribe to topics” field, and that has done the trick well enough, sorry for the trouble.


    Robin W
    Moderator

    @robin-w

    Glad you’re sorted

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

You must be logged in to reply to this topic.