Changeset 9936 for trunk/src/bp-members/bp-members-loader.php
- Timestamp:
- 06/11/2015 06:53:59 AM (11 years ago)
- File:
-
- 1 edited
-
trunk/src/bp-members/bp-members-loader.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-members/bp-members-loader.php
r9877 r9936 142 142 /** Profiles Fallback *************************************************/ 143 143 144 if ( ! bp_is_active( 'xprofile' ) ) {144 if ( ! bp_is_active( 'xprofile' ) ) { 145 145 $bp->profile = new stdClass; 146 146 $bp->profile->slug = 'profile'; … … 231 231 } 232 232 233 $bp = buddypress(); 233 // Determine user to use 234 if ( bp_displayed_user_domain() ) { 235 $user_domain = bp_displayed_user_domain(); 236 } elseif ( bp_loggedin_user_domain() ) { 237 $user_domain = bp_loggedin_user_domain(); 238 } else { 239 return; 240 } 241 242 $slug = bp_get_profile_slug(); 243 $profile_link = trailingslashit( $user_domain . $slug ); 234 244 235 245 // Setup the main navigation 236 246 $main_nav = array( 237 247 'name' => _x( 'Profile', 'Member profile main navigation', 'buddypress' ), 238 'slug' => $ bp->profile->slug,248 'slug' => $slug, 239 249 'position' => 20, 240 250 'screen_function' => 'bp_members_screen_display_profile', 241 251 'default_subnav_slug' => 'public', 242 'item_css_id' => $bp->profile->id 243 ); 244 245 // User links 246 $user_domain = bp_displayed_user_domain() ? bp_displayed_user_domain() : bp_loggedin_user_domain(); 247 $profile_link = trailingslashit( $user_domain . $bp->profile->slug ); 252 'item_css_id' => buddypress()->profile->id 253 ); 248 254 249 255 // Setup the subnav items for the member profile … … 252 258 'slug' => 'public', 253 259 'parent_url' => $profile_link, 254 'parent_slug' => $ bp->profile->slug,260 'parent_slug' => $slug, 255 261 'screen_function' => 'bp_members_screen_display_profile', 256 262 'position' => 10
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)