Changeset 12547 for trunk/src/bp-core/deprecated/2.1.php
- Timestamp:
- 01/29/2020 09:43:16 PM (6 years ago)
- File:
-
- 1 edited
-
trunk/src/bp-core/deprecated/2.1.php (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-core/deprecated/2.1.php
r12401 r12547 8 8 */ 9 9 10 // Exit if accessed directly 10 // Exit if accessed directly. 11 11 defined( 'ABSPATH' ) || exit; 12 12 … … 190 190 echo '<li class="bp-login no-arrow"><a href="' . wp_login_url() . '">' . __( 'Log In', 'buddypress' ) . '</a></li>'; 191 191 192 // Show "Sign Up" link if user registrations are allowed 192 // Show "Sign Up" link if user registrations are allowed. 193 193 if ( bp_get_signup_allowed() ) { 194 194 echo '<li class="bp-signup no-arrow"><a href="' . bp_get_signup_page() . '">' . __( 'Sign Up', 'buddypress' ) . '</a></li>'; … … 214 214 echo '<ul>'; 215 215 216 // Loop through each navigation item 216 // Loop through each navigation item. 217 217 $counter = 0; 218 218 foreach( (array) $bp->bp_nav as $nav_item ) { … … 327 327 $min = bp_core_get_minified_asset_suffix(); 328 328 329 if ( file_exists( get_stylesheet_directory() . '/_inc/css/adminbar.css' ) ) { // Backwards compatibility 329 if ( file_exists( get_stylesheet_directory() . '/_inc/css/adminbar.css' ) ) { // Backwards compatibility. 330 330 $stylesheet = get_stylesheet_directory_uri() . '/_inc/css/adminbar.css'; 331 331 } else { … … 356 356 } 357 357 358 // Only group admins and site admins can see this menu 358 // Only group admins and site admins can see this menu. 359 359 if ( !current_user_can( 'edit_users' ) && !bp_current_user_can( 'bp_moderate' ) && !bp_is_item_admin() ) { 360 360 return false; … … 407 407 function bp_adminbar_notifications_menu() { 408 408 409 // Bail if notifications is not active 409 // Bail if notifications is not active. 410 410 if ( ! bp_is_active( 'notifications' ) ) { 411 411 return false; … … 424 424 global $wpdb; 425 425 426 // Only for multisite 426 // Only for multisite. 427 427 if ( ! is_multisite() ) { 428 428 return false; 429 429 } 430 430 431 // Hide on root blog 431 // Hide on root blog. 432 432 if ( bp_is_root_blog( $wpdb->blogid ) || ! bp_is_active( 'blogs' ) ) { 433 433 return false; … … 438 438 439 439 if ( !empty( $authors ) ) { 440 // This is a blog, render a menu with links to all authors 440 // This is a blog, render a menu with links to all authors. 441 441 echo '<li id="bp-adminbar-authors-menu"><a href="/">'; 442 442 _e('Blog Authors', 'buddypress'); … … 479 479 function bp_members_adminbar_admin_menu() { 480 480 481 // Only show if viewing a user 481 // Only show if viewing a user. 482 482 if ( ! bp_displayed_user_id() ) { 483 483 return false; 484 484 } 485 485 486 // Don't show this menu to non site admins or if you're viewing your own profile 486 // Don't show this menu to non site admins or if you're viewing your own profile. 487 487 if ( !current_user_can( 'edit_users' ) || bp_is_my_profile() ) { 488 488 return false;
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)