Skip to:
Content
Pages
Categories
Search
Top
Bottom

Forum Replies Created

Viewing 6 replies - 1 through 6 (of 6 total)
  • @pinkishhue

    Participant

    Thanks for sharing this link, very helpful 🙂

    It’s perhaps been discussed before but it seems like this should be a default feature for Buddypress/bbpress, including notifications for subscribed forums AND topics within the alert.

    I need this function for new replies on topics and unfortunately this plugin doesn’t do that.

    I will keep looking.

    @pinkishhue

    Participant

    Try <?php bp_displayed_user_username(); ?>

    @pinkishhue

    Participant

    Hi Joe,

    I don’t think there is a setting you can change for that specifically but you can restrict access to the content on that page and similar pages by adding a conditional in to their templates.

    You need to copy over the relevant template from here:

    …\wp-content\plugins\buddypress\bp-templates\bp-legacy\buddypress\

    and put it in to your theme here:

    …\wp-content\themes\your-theme\buddypress\

    so for example for that particular page, the friends list on a user profile, you would copy this file:

    …\wp-content\plugins\buddypress\bp-templates\bp-legacy\buddypress\members\single\friends.php

    and put it here:

    …\wp-content\themes\your-theme\buddypress\members\single\friends.php

    then open up that file in a text editor and add this code near the top (under the first closing ?>)

    <?php if ( is_user_logged_in() ) : ?>

    Then right at the end of that file, add this code:

    <?php endif; ?>

    That should work but I haven’t tested it as I don’t have access to my main PC right now. That will show the normal header and footer but none of the friends list content.

    Alternatively if you wanted to show an error message like ‘you need to be logged in’ you could use something like this in place of that first snippet of code:

    <?php if ( !is_user_logged_in() ) : ?>
    
    <p>You need to be logged in to view this content</p>
    
    <?php else : ?>

    Hope that helps 🙂

    @pinkishhue

    Participant

    Ooh apologies. I was searching ‘audio’ and ‘sound’ etc. Didn’t consider ‘acoustic’! Wil check it out.

    @pinkishhue

    Participant

    @rglennall I’m assuming this should go in your bp-custom.php file, see info here if unfamiliar:

    bp-custom.php

    Hope that helps!

    @pinkishhue

    Participant

    I’ve been thinking of this a lot myself, in the way that Facebook or Gmail for example update their title tags. This is a great way of encouraging engagement in the site as people see the number even if their browser is minimised and they’re off working on something else.

    I haven’t tried to implement this myself yet but will have a try asap.

    I guess it’s a case of:

    adding a conditional in to the <title > tag in the themes header.php that says IF there are notifications then display the count. Then, have the page refresh periodically to update the count (or does buddypress do this already to update notifications? I’d have to check)

    So just need to find the code that generates the notifications count.

    Hopefully it’s that simple, but we’ll see 🙂

Viewing 6 replies - 1 through 6 (of 6 total)
Skip to toolbar