BuddyDev

Search

Code conflict

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46143

    Hello Brajesh,

    I am using the code below to filter activity directory, but clicking the mentions tab is not working. Clicking the mentions tab still loads following content instead of @ mentions content.

     /* Filter sitewide activity to list following user's activity. */
    function bp_custom_list_activities_filter( $args ) {
    	if ( ! is_user_logged_in() || ! bp_is_activity_directory() ) {
    		return $args;
    	}
    	// for logged in user, change scope to following.
    	$args['scope'] = 'following';
    
    	return $args;
    }
    add_filter( 'bp_after_has_activities_parse_args', 'bp_custom_list_activities_filter' ); 

    Thanks

  • Keymaster
    (BuddyDev Team)
    Posts: 21785
    Brajesh Singh on #46150

    Hi Tosin.
    The code will overwrite everything in favour of the follow.

    What is your goal with the follow filter? Please let me know and I may be able to assist you.

    Regards
    Brajesh

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46152

    OHH OK

    I’ve decided to stop using the code above and reuse the Facebook like activity stream plugin, now while using the plugin ill like to achieve the following

    1. Remove the following tab in sitewide activity directory

    2. I recently noticed an issue with the Facebook like activity stream plugin, when a user logs in to the sitewide activity directory the activities of users im following is loaded and everything works smoothly but when I click on a different tab like (favorites tab) or (mentions tab) and click back to (All members tab) the content loaded now changes to activities of all members on the site instead of enforcing only the content of members im following.

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46179

    Please note that I dont want to hide the Following tab using css

  • Keymaster
    (BuddyDev Team)
    Posts: 21785
    Brajesh Singh on #46180

    Hi Tosin,
    I don’t have follow plugin active at the moment. will be looking at it when I have some time after releasing some of our plugins next week.

    Regards
    Brajesh

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46240

    Gentle reminder sir

    Thanks

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46314

    kind reminder boss

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46388

    Another reminder sir

    Thanks

  • Keymaster
    (BuddyDev Team)
    Posts: 21785
    Brajesh Singh on #46396

    Hi Tosin,
    I am sorry, I am unable to help you with custom codes due to lack of available time.

    I will ask one of my teams members to see if they can assist you. is your problem that the Facebook like activity is not showing stream activity correctly? Have you tried it after disabling all your custom codes and 3rd party plugins/themes.

    If yes, Please list us the active plugins, theme and template pack.

    Regards
    Brajesh

  • Participant
    Level: Guru
    Posts: 701
    Tosin on #46408

    I just want two tabs in the activity directory page which are (News Feed/All Activities) and (Mentions) tab.
    I have removed all other tabs except the (following) tab what I want to achieve now is

    1. Remove the following tab in sitewide activity directory

    2. When a user logs in to the sitewide activity directory the activities of users im following is loaded and everything works smoothly but when I click on a different tab like (favorites tab) or (mentions tab) and click back to (All members tab) the content loaded now changes to activities of all members on the site instead of enforcing only the content of members im following.

    Im using legacy template

You must be logged in to reply to this topic.

This topic is: not resolved