Skip to:
Content

BuddyPress.org

Ticket #2955: buddypress-jeff.patch

File buddypress-jeff.patch, 23.0 KB (added by jefferai, 14 years ago)
  • buddypress/bp-activity/bp-activity-templatetags.php

    diff -ru buddypress/bp-activity/bp-activity-templatetags.php htdocs/wp-content/plugins/buddypress/bp-activity/bp-activity-templatetags.php
    old new  
    155155                $object = $bp->groups->id;
    156156                $primary_id = $bp->groups->current_group->id;
    157157
    158                 if ( 'public' != $bp->groups->current_group->status && ( groups_is_user_member( $bp->loggedin_user->id, $bp->groups->current_group->id ) || $bp->loggedin_user->is_super_admin ) )
     158                if ( 'public' != $bp->groups->current_group->status && 'modmems' != $bp->groups->current_group->status && ( groups_is_user_member( $bp->loggedin_user->id, $bp->groups->current_group->id ) || $bp->loggedin_user->is_super_admin ) )
    159159                        $show_hidden = true;
    160160        }
    161161
     
    10001000                else if ( 'mentions' == $bp->current_action )
    10011001                        $link = $bp->displayed_user->domain . $bp->activity->slug . '/mentions/feed/';
    10021002
    1003                 return apply_filters( 'bp_get_activities_member_rss_link', $link );
     1003                return apply_filters( 'bp_get_activities_member_feed_link', $link );
    10041004        }
    10051005        function bp_get_activities_member_rss_link() { return bp_get_member_activity_feed_link(); }
    10061006
     1007function bp_get_member_current_activity_feed_title() {
     1008        global $bp;
     1009
     1010        if ( $bp->current_component == $bp->profile->slug || 'just-me' == $bp->current_action )
     1011                $name = 'Personal';
     1012        else if ( 'friends' == $bp->current_action )
     1013                $name = 'Friends';
     1014        else if ( 'groups' == $bp->current_action )
     1015                $name = 'Groups';
     1016        else if ( 'favorites' == $bp->current_action )
     1017                $name = 'Favorites';
     1018        else if ( 'mentions' == $bp->current_action )
     1019                $name = 'Mentions';
     1020        else if ( 'blogs' == $bp->current_action )
     1021                $name = 'Blogs';
     1022
     1023        return apply_filters( 'bp_get_activity_current_feed_title', $name );
     1024}
     1025        function bp_member_current_activity_feed_title() { return bp_get_member_current_activity_feed_title(); }
     1026        function bp_member_current_activity_rss_title() { return bp_get_member_current_activity_feed_title(); }
     1027       
     1028
    10071029
    10081030/* Template tags for RSS feed output */
    10091031
     
    10711093                return apply_filters( 'bp_get_activity_feed_item_description', html_entity_decode( str_replace( '%s', '', $content ) ) );
    10721094        }
    10731095
    1074 ?>
    1075  No newline at end of file
     1096?>
  • buddypress/bp-activity.php

    diff -ru buddypress/bp-activity.php htdocs/wp-content/plugins/buddypress/bp-activity.php
    old new  
    12121212add_action( 'bp_loaded', 'bp_register_activity_actions', 8 );
    12131213
    12141214
    1215 ?>
    1216  No newline at end of file
     1215?>
  • buddypress/bp-core/bp-core-avatars.php

    diff -ru buddypress/bp-core/bp-core-avatars.php htdocs/wp-content/plugins/buddypress/bp-core/bp-core-avatars.php
    old new  
    476476 * @param string $alt Alternate text to use in image tag. Defaults to blank
    477477 * @return <type>
    478478 */
    479 function bp_core_fetch_avatar_filter( $avatar, $user, $size, $default, $alt ) {
     479function bp_core_fetch_avatar_filter( $avatar, $user, $size, $default, $alt = '' ) {
    480480        global $pagenow;
    481481       
    482482        // Do not filter if inside WordPress options page
     
    572572        return apply_filters( 'bp_core_avatar_url', $upload_dir['baseurl'] );
    573573}
    574574
    575 ?>
    576  No newline at end of file
     575?>
  • buddypress/bp-groups/bp-groups-classes.php

    diff -ru buddypress/bp-groups/bp-groups-classes.php htdocs/wp-content/plugins/buddypress/bp-groups/bp-groups-classes.php
    old new  
    467467
    468468                // Limit results to public status
    469469                if ( $only_public )
    470                         $where_conditions[] = $wpdb->prepare( "g.status = 'public'" );
     470                        $where_conditions[] = $wpdb->prepare( "(g.status = 'public' OR g.status = 'modmems')" );
    471471
    472472                if ( !is_super_admin() )
    473473                        $where_conditions[] = $wpdb->prepare( "g.status != 'hidden'");
     
    618618
    619619                $extra_sql = apply_filters( 'groups_total_public_forum_topic_count', $bp->groups->filter_sql, $type );
    620620
    621                 return $wpdb->get_var( "SELECT COUNT(t.topic_id) FROM {$bbdb->topics} AS t, {$bp->groups->table_name} AS g LEFT JOIN {$bp->groups->table_name_groupmeta} AS gm ON g.id = gm.group_id WHERE (gm.meta_key = 'forum_id' AND gm.meta_value = t.forum_id) AND g.status = 'public' AND t.topic_status = '0' AND t.topic_sticky != '2' {$extra_sql} " );
     621                return $wpdb->get_var( "SELECT COUNT(t.topic_id) FROM {$bbdb->topics} AS t, {$bp->groups->table_name} AS g LEFT JOIN {$bp->groups->table_name_groupmeta} AS gm ON g.id = gm.group_id WHERE (gm.meta_key = 'forum_id' AND gm.meta_value = t.forum_id) AND (g.status = 'public' OR g.status = 'modmems') AND t.topic_status = '0' AND t.topic_sticky != '2' {$extra_sql} " );
    622622        }
    623623
    624624        function get_total_member_count( $group_id ) {
     
    821821                if ( $limit && $page )
    822822                        $pag_sql = $wpdb->prepare( " LIMIT %d, %d", intval( ( $page - 1 ) * $limit), intval( $limit ) );
    823823
    824                 // If the user is logged in and viewing their own groups, we can show hidden and private groups
     824                // If the user is logged in and viewing their own groups, we can show hidden,  private and moderated-membership groups
    825825                if ( $user_id != $bp->loggedin_user->id ) {
    826826                        $group_sql = $wpdb->prepare( "SELECT DISTINCT m.group_id FROM {$bp->groups->table_name_members} m, {$bp->groups->table_name} g WHERE g.status != 'hidden' AND m.user_id = %d AND m.is_confirmed = 1 AND m.is_banned = 0{$pag_sql}", $user_id );
    827827                        $total_groups = $wpdb->get_var( $wpdb->prepare( "SELECT COUNT(DISTINCT m.group_id) FROM {$bp->groups->table_name_members} m, {$bp->groups->table_name} g WHERE g.status != 'hidden' AND m.user_id = %d AND m.is_confirmed = 1 AND m.is_banned = 0", $user_id ) );
     
    10131013        function get_random_groups( $user_id, $total_groups = 5 ) {
    10141014                global $wpdb, $bp;
    10151015
    1016                 // If the user is logged in and viewing their random groups, we can show hidden and private groups
     1016                // If the user is logged in and viewing their random groups, we can show hidden, private and moderated-membership groups
    10171017                if ( bp_is_my_profile() ) {
    10181018                        return $wpdb->get_col( $wpdb->prepare( "SELECT DISTINCT group_id FROM {$bp->groups->table_name_members} WHERE user_id = %d AND is_confirmed = 1 AND is_banned = 0 ORDER BY rand() LIMIT $total_groups", $user_id ) );
    10191019                } else {
  • buddypress/bp-groups/bp-groups-filters.php

    diff -ru buddypress/bp-groups/bp-groups-filters.php htdocs/wp-content/plugins/buddypress/bp-groups/bp-groups-filters.php
    old new  
    6565        global $bp;
    6666
    6767        /* Only filter the forum SQL on group pages or on the forums directory */
    68         if ( ( $bp->groups->current_group && 'public' == $bp->groups->current_group->status ) || !$bp->groups->current_group ) {
     68        if ( ( $bp->groups->current_group && ( 'public' == $bp->groups->current_group->status || 'modmems' == $bp->groups->current_group->status ) ) || !$bp->groups->current_group ) {
    6969                add_filter( 'get_topics_fields', 'groups_add_forum_fields_sql' );
    7070                add_filter( 'get_topics_index_hint', 'groups_add_forum_tables_sql' );
    7171                add_filter( 'get_topics_where', 'groups_add_forum_where_sql' );
     
    8686        global $bp;
    8787
    8888        $bp->groups->filter_sql = ' AND ' . $sql;
    89         return "(gm.meta_key = 'forum_id' AND gm.meta_value = t.forum_id) AND g.status = 'public' AND " . $sql;
     89        return "(gm.meta_key = 'forum_id' AND gm.meta_value = t.forum_id) AND (g.status = 'public' OR g.status = 'modmems') AND " . $sql;
    9090}
    9191
    9292function groups_filter_bbpress_caps( $value, $cap, $args ) {
     
    105105}
    106106add_filter( 'bb_current_user_can', 'groups_filter_bbpress_caps', 10, 3 );
    107107
    108 ?>
    109  No newline at end of file
     108?>
  • buddypress/bp-groups/bp-groups-templatetags.php

    diff -ru buddypress/bp-groups/bp-groups-templatetags.php htdocs/wp-content/plugins/buddypress/bp-groups/bp-groups-templatetags.php
    old new  
    204204        if ( !$group )
    205205                $group =& $groups_template->group;
    206206
    207         if ( 'public' == $group->status ) {
     207        if ( 'public' == $group->status || 'modmems' == $group->status ) {
    208208                return true;
    209209        } else {
    210210                if ( groups_is_user_member( $bp->loggedin_user->id, $group->id ) ) {
     
    250250
    251251                if ( 'public' == $group->status ) {
    252252                        $type = __( "Public Group", "buddypress" );
     253                } else if ( 'modmems' == $group->status ) {
     254                        $type = __( "Moderated-Membership Group", "buddypress" );
    253255                } else if ( 'hidden' == $group->status ) {
    254256                        $type = __( "Hidden Group", "buddypress" );
    255257                } else if ( 'private' == $group->status ) {
     
    415417                if ( !$group )
    416418                        $group =& $groups_template->group;
    417419
    418                 if ( $group->is_public ) {
     420                if ( $group->status == 'public' ) {
    419421                        return __( 'Public', 'buddypress' );
     422                } elseif ( $group->status == 'modmems' ) {
     423                        return __( 'Moderated-Membership', 'buddypress' );
    420424                } else {
    421425                        return __( 'Private', 'buddypress' );
    422426                }
     
    930934        <li<?php if ( 'group-avatar' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->root_domain . '/' . $bp->groups->slug ?>/<?php echo $group->slug ?>/admin/group-avatar"><?php _e('Group Avatar', 'buddypress') ?></a></li>
    931935        <li<?php if ( 'manage-members' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->root_domain . '/' . $bp->groups->slug ?>/<?php echo $group->slug ?>/admin/manage-members"><?php _e('Manage Members', 'buddypress') ?></a></li>
    932936
    933         <?php if ( $groups_template->group->status == 'private' ) : ?>
     937        <?php if ( $groups_template->group->status == 'private' || $group_template->group->status == 'modmems' ) : ?>
    934938                <li<?php if ( 'membership-requests' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->root_domain . '/' . $bp->groups->slug ?>/<?php echo $group->slug ?>/admin/membership-requests"><?php _e('Membership Requests', 'buddypress') ?></a></li>
    935939        <?php endif; ?>
    936940
     
    10951099        return true;
    10961100}
    10971101
     1102function bp_group_can_post_new_topic( $group = false ) {
     1103        global $groups_template;
     1104
     1105        if ( !bp_is_group_forum() || !is_user_logged_in() || bp_is_group_forum_topic() )
     1106                return false;
     1107       
     1108        if ( !$group )
     1109                $group =& $groups_template->group;
     1110
     1111        if ( $group->status == 'modmems' && !$group->is_member )
     1112                return false;
     1113}
     1114
    10981115function bp_group_new_topic_button() {
    1099         if ( bp_is_group_forum() && is_user_logged_in() && !bp_is_group_forum_topic() ) {
     1116        if ( bp_group_can_post_new_topic() ) {
    11001117                bp_button( array (
    11011118                        'id'                => 'new_topic',
    11021119                        'component'         => 'groups',
     
    11731190                                        break;
    11741191
    11751192                                case 'private' :
     1193                                case 'modmems' :
    11761194
    11771195                                        // Member has not requested membership yet
    11781196                                        if ( !bp_group_has_requested_membership( $group ) ) {
     
    12191237        if ( !$group )
    12201238                $group =& $groups_template->group;
    12211239
    1222         if ( 'private' == $group->status ) {
     1240        $privstatus = null;
     1241
     1242        if ( 'private' == $group->status )
     1243                $privstatus = 'private';
     1244        if ( 'modmems' == $group->status )
     1245                $privstatus = 'moderated-membership';
     1246
     1247        if ( $privstatus ) {
    12231248                if ( !bp_group_has_requested_membership() )
    12241249                        if ( is_user_logged_in() )
    1225                                 _e( 'This is a private group and you must request group membership in order to join.', 'buddypress' );
     1250                                _e( 'This is a ' . $privstatus . ' group and you must request group membership in order to join.', 'buddypress' );
    12261251                        else
    1227                                 _e( 'This is a private group. To join you must be a registered site member and request group membership.', 'buddypress' );
     1252                                _e( 'This is a ' . $privstatus . ' group. To join you must be a registered site member and request group membership.', 'buddypress' );
    12281253                else
    1229                         _e( 'This is a private group. Your membership request is awaiting approval from the group administrator.', 'buddypress' );
     1254                        _e( 'This is a ' . $privstatus . ' group. Your membership request is awaiting approval from the group administrator.', 'buddypress' );
    12301255        } else {
    12311256                _e( 'This is a hidden group and only invited members can join.', 'buddypress' );
    12321257        }
     
    22712296                $name = apply_filters( 'bp_get_group_name', $bp->groups->current_group->name );
    22722297                return apply_filters( 'bp_get_current_group_name', $name );
    22732298        }
    2274 ?>
    2275  No newline at end of file
     2299?>
  • buddypress/bp-groups.php

    diff -ru buddypress/bp-groups.php htdocs/wp-content/plugins/buddypress/bp-groups.php
    old new  
    9696        if ( bp_is_active( 'friends' ) )
    9797                $bp->groups->group_creation_steps['group-invites'] = array( 'name' => __( 'Invites', 'buddypress' ), 'position' => 30 );
    9898
    99         $bp->groups->valid_status = apply_filters( 'groups_valid_status', array( 'public', 'private', 'hidden' ) );
     99        $bp->groups->valid_status = apply_filters( 'groups_valid_status', array( 'public', 'private', 'hidden', 'modmems' ) );
    100100
    101101        // Auto join group when non group member performs group activity
    102102        $bp->groups->auto_join = defined( 'BP_DISABLE_AUTO_GROUP_JOIN' ) ? false : true;
     
    141141                $bp->groups->current_group->is_user_member = ( is_user_logged_in() && groups_is_user_member( $bp->loggedin_user->id, $bp->groups->current_group->id ) ) ? true : false;
    142142
    143143                /* Should this group be visible to the logged in user? */
    144                 $bp->groups->current_group->is_group_visible_to_member = ( 'public' == $bp->groups->current_group->status || $is_member ) ? true : false;
     144                $bp->groups->current_group->is_group_visible_to_member = ( 'public' == $bp->groups->current_group->status || 'modmems' == $bp->groups->current_group_status || $is_member ) ? true : false;
    145145        }
    146146
    147147        /* Add 'Groups' to the main navigation */
     
    204204                        if ( $bp->is_item_mod || $bp->is_item_admin )
    205205                                bp_core_new_subnav_item( array( 'name' => __( 'Admin', 'buddypress' ), 'slug' => 'admin', 'parent_url' => $group_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_group_admin', 'position' => 20, 'user_has_access' => ( $bp->is_item_admin + (int)$bp->is_item_mod ), 'item_css_id' => 'admin' ) );
    206206
    207                         // If this is a private group, and the user is not a member, show a "Request Membership" nav item.
    208                         if ( !is_super_admin() && is_user_logged_in() && !$bp->groups->current_group->is_user_member && !groups_check_for_membership_request( $bp->loggedin_user->id, $bp->groups->current_group->id ) && $bp->groups->current_group->status == 'private' )
     207                        // If this is a private or moderated-membership group, and the user is not a member, show a "Request Membership" nav item.
     208                        if ( !is_super_admin() && is_user_logged_in() && !$bp->groups->current_group->is_user_member && !groups_check_for_membership_request( $bp->loggedin_user->id, $bp->groups->current_group->id ) && ( $bp->groups->current_group->status == 'private' || $bp->groups->current_group->status == 'modmems' ) )
    209209                                bp_core_new_subnav_item( array( 'name' => __( 'Request Membership', 'buddypress' ), 'slug' => 'request-membership', 'parent_url' => $group_link, 'parent_slug' => $bp->groups->slug, 'screen_function' => 'groups_screen_group_request_membership', 'position' => 30 ) );
    210210
    211211                        if ( $bp->groups->current_group->enable_forum && function_exists('bp_forums_setup') )
     
    607607        if ( !is_user_logged_in() )
    608608                return false;
    609609
    610         if ( 'private' == $bp->groups->current_group->status ) {
     610        if ( 'private' == $bp->groups->current_group->status || 'modmems' == $bp->groups->current_group->status ) {
    611611                // If the user has submitted a request, send it.
    612612                if ( isset( $_POST['group-request-send']) ) {
    613613                        /* Check the nonce first. */
     
    696696                if ( isset( $_POST['save'] ) ) {
    697697                        $enable_forum = ( isset($_POST['group-show-forum'] ) ) ? 1 : 0;
    698698
    699                         $allowed_status = apply_filters( 'groups_allowed_status', array( 'public', 'private', 'hidden' ) );
     699                        $allowed_status = apply_filters( 'groups_allowed_status', array( 'public', 'private', 'hidden', 'modmems' ) );
    700700                        $status = ( in_array( $_POST['group-status'], (array)$allowed_status ) ) ? $_POST['group-status'] : 'public';
    701701
    702702                        /* Check the nonce first. */
     
    10101010                        </tr>
    10111011                        <tr>
    10121012                                <td></td>
    1013                                 <td><?php _e( 'A member requests to join a private group for which you are an admin', 'buddypress' ) ?></td>
     1013                                <td><?php _e( 'A member requests to join a private or moderated-membership group for which you are an admin', 'buddypress' ) ?></td>
    10141014                                <td class="yes"><input type="radio" name="notifications[notification_groups_membership_request]" value="yes" <?php if ( !get_user_meta( $current_user->id, 'notification_groups_membership_request', true ) || 'yes' == get_user_meta( $current_user->id, 'notification_groups_membership_request', true ) ) { ?>checked="checked" <?php } ?>/></td>
    10151015                                <td class="no"><input type="radio" name="notifications[notification_groups_membership_request]" value="no" <?php if ( 'no' == get_user_meta( $current_user->id, 'notification_groups_membership_request', true ) ) { ?>checked="checked" <?php } ?>/></td>
    10161016                        </tr>
     
    11091109
    11101110                        if ( 'private' == $_POST['group-status'] )
    11111111                                $group_status = 'private';
     1112                        else if ( 'modmems' == $_POST['group-status'] )
     1113                                $group_status = 'modmems';
    11121114                        else if ( 'hidden' == $_POST['group-status'] )
    11131115                                $group_status = 'hidden';
    11141116
     
    13061308        $wp_query->is_404 = false;
    13071309        status_header( 200 );
    13081310
    1309         if ( 'public' != $bp->groups->current_group->status ) {
     1311        if ( 'public' != $bp->groups->current_group->status && 'modmems' != $bp->groups->current_group->status ) {
    13101312                if ( !groups_is_user_member( $bp->loggedin_user->id, $bp->groups->current_group->id ) )
    13111313                        return false;
    13121314        }
     
    13461348                return false;
    13471349
    13481350        /* If the group is not public, hide the activity sitewide. */
    1349         if ( 'public' == $bp->groups->current_group->status )
     1351        if ( 'public' == $bp->groups->current_group->status || 'modmems' == $bp->groups->current_group->status )
    13501352                $hide_sitewide = false;
    13511353        else
    13521354                $hide_sitewide = true;
     
    16021604         * Before we potentially switch the group status, if it has been changed to public
    16031605         * from private and there are outstanding membership requests, auto-accept those requests.
    16041606         */
    1605         if ( 'private' == $group->status && 'public' == $status )
     1607        if ( ( 'private' == $group->status || 'modmems' == $group->status ) && 'public' == $status )
    16061608                groups_accept_all_pending_membership_requests( $group->id );
    16071609
    16081610        /* Now update the status */
  • buddypress/bp-themes/bp-default/forums/index.php

    diff -ru buddypress/bp-themes/bp-default/forums/index.php htdocs/wp-content/plugins/buddypress/bp-themes/bp-default/forums/index.php
    old new  
    4242
    4343                                                        <?php while ( bp_groups() ) : bp_the_group(); ?>
    4444
    45                                                                 <?php if ( bp_group_is_forum_enabled() && 'public' == bp_get_group_status() ) : ?>
     45                                                                <?php if ( bp_group_is_forum_enabled() && ( 'public' == bp_get_group_status() || bp_group_is_member() ) ) : ?>
    4646
    4747                                                                        <option value="<?php bp_group_id() ?>"><?php bp_group_name() ?></option>
    4848
     
    117117
    118118        <?php locate_template( array( 'sidebar.php' ), true ) ?>
    119119
    120 <?php get_footer() ?>
    121  No newline at end of file
     120<?php get_footer() ?>
  • buddypress/bp-themes/bp-default/groups/create.php

    diff -ru buddypress/bp-themes/bp-default/groups/create.php htdocs/wp-content/plugins/buddypress/bp-themes/bp-default/groups/create.php
    old new  
    7474                                                        </ul>
    7575                                                </label>
    7676
     77                                                <label><input type="radio" name="group-status" value="modmems"<?php if ( 'modmems' == bp_get_new_group_status() ) { ?> checked="checked"<?php } ?> />
     78                                                        <strong><?php _e( 'This is a moderated-membership group', 'buddypress' ) ?></strong>
     79                                                        <ul>
     80                                                                <li><?php _e( 'Only users who request membership and are accepted can join the group.', 'buddypress' ) ?></li>
     81                                                                <li><?php _e( 'This group will be listed in the groups directory and in search results.', 'buddypress' ) ?></li>
     82                                                                <li><?php _e( 'Group content and activity will be visible to any site member.', 'buddypress' ) ?></li>
     83                                                        </ul>
     84                                                </label>
     85
    7786                                                <label><input type="radio" name="group-status" value="private"<?php if ( 'private' == bp_get_new_group_status() ) { ?> checked="checked"<?php } ?> />
    7887                                                        <strong><?php _e( 'This is a private group', 'buddypress' ) ?></strong>
    7988                                                        <ul>
  • buddypress/bp-themes/bp-default/groups/single/admin.php

    diff -ru buddypress/bp-themes/bp-default/groups/single/admin.php htdocs/wp-content/plugins/buddypress/bp-themes/bp-default/groups/single/admin.php
    old new  
    7575                </label>
    7676
    7777                <label>
     78                        <input type="radio" name="group-status" value="modmems"<?php bp_group_show_status_setting('modmems') ?> />
     79                        <strong><?php _e( 'This is a moderated-membership group', 'buddypress' ) ?></strong>
     80                        <ul>
     81                                <li><?php _e( 'Only users who request membership and are accepted can join the group.', 'buddypress' ) ?></li>
     82                                <li><?php _e( 'This group will be listed in the groups directory and in search results.', 'buddypress' ) ?></li>
     83                                <li><?php _e( 'Group content and activity will be visible to any site member.', 'buddypress' ) ?></li>
     84                        </ul>
     85                </label>
     86
     87                <label>
    7888                        <input type="radio" name="group-status" value="private"<?php bp_group_show_status_setting('private') ?> />
    7989                        <strong><?php _e( 'This is a private group', 'buddypress' ) ?></strong>
    8090                        <ul>
  • buddypress/bp-themes/bp-default/header.php

    diff -ru buddypress/bp-themes/bp-default/header.php htdocs/wp-content/plugins/buddypress/bp-themes/bp-default/header.php
    old new  
    1818                        <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> | <?php _e('Site Wide Activity RSS Feed', 'buddypress' ) ?>" href="<?php bp_sitewide_activity_feed_link() ?>" />
    1919                <?php endif; ?>
    2020
    21                 <?php if ( function_exists( 'bp_member_activity_feed_link' ) && bp_is_member() ) : ?>
    22                         <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> | <?php bp_displayed_user_fullname() ?> | <?php _e( 'Activity RSS Feed', 'buddypress' ) ?>" href="<?php bp_member_activity_feed_link() ?>" />
     21                <?php if ( function_exists( 'bp_member_activity_feed_link' ) && bp_is_member() && bp_is_activity_component() ) : ?>
     22                        <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> | <?php bp_displayed_user_fullname() ?> | <?php _e( bp_member_current_activity_rss_title() . ' Activity RSS Feed', 'buddypress' ) ?>" href="<?php bp_member_activity_feed_link() ?>" />
    2323                <?php endif; ?>
    2424
    2525                <?php if ( function_exists( 'bp_group_activity_feed_link' ) && bp_is_group() ) : ?>