Changeset 5313 for trunk/bp-core/bp-core-buddybar.php
- Timestamp:
- 11/08/2011 09:37:42 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/bp-core/bp-core-buddybar.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/bp-core-buddybar.php
r5295 r5313 70 70 add_action( 'bp_screens', array( &$screen_function[0], $screen_function[1] ), 3 ); 71 71 72 if ( !empty( $default_subnav_slug ) ) 73 $bp->current_action = apply_filters( 'bp_default_component_subnav', $default_subnav_slug, $r ); 72 if ( !empty( $default_subnav_slug ) ) { 73 /** 74 * BuddyPress will attempt to resolve to the most specific URL possible, 75 * to avoid search-engine-unfriendly content reduplication. Filter 76 * bp_guarantee_unique_uris (and return false) to avoid this behavior 77 */ 78 if ( apply_filters( 'bp_guarantee_unique_uris', true ) ) { 79 bp_core_redirect( bp_displayed_user_domain() . $slug . '/' . apply_filters( 'bp_default_component_subnav', $default_subnav_slug, $r ) ); 80 } else { 81 $bp->current_action = apply_filters( 'bp_default_component_subnav', $default_subnav_slug, $r ); 82 } 83 } 74 84 75 85 // Look for current item … … 80 90 add_action( 'bp_screens', array( &$screen_function[0], $screen_function[1] ), 3 ); 81 91 82 if ( !empty( $default_subnav_slug ) ) 83 $bp->current_action = apply_filters( 'bp_default_component_subnav', $default_subnav_slug, $r ); 92 if ( !empty( $default_subnav_slug ) ) { 93 /** 94 * BuddyPress will attempt to resolve to the most specific URL possible, 95 * to avoid search-engine-unfriendly content reduplication. Filter 96 * bp_guarantee_unique_uris (and return false) to avoid this behavior 97 */ 98 if ( apply_filters( 'bp_guarantee_unique_uris', true ) ) { 99 bp_core_redirect( bp_get_root_domain() . '/' . bp_get_root_slug( bp_current_component() ) . '/' . $slug . '/' . apply_filters( 'bp_default_component_subnav', $default_subnav_slug, $r ) ); 100 } else { 101 $bp->current_action = apply_filters( 'bp_default_component_subnav', $default_subnav_slug, $r ); 102 } 103 } 84 104 } 85 105
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)