Skip to:
Content

BuddyPress.org

Opened 14 years ago

Closed 14 years ago

Last modified 13 years ago

#4454 closed defect (bug) (no action required)

Filtering tabs names causes counter to disappear

Reported by: modemlooper's profile modemlooper Owned by:
Milestone: Priority: normal
Severity: trivial Version: 1.6
Component: Messages Keywords: reporter-feedback close
Cc:

Description

The numbers next to tabs like messages and friends disappears when you filter the names with

$bp->bp_nav['messages']['name']

]

Change History (7)

#1 @DJPaul
14 years ago

  • Keywords reporter-feedback added

What value are you assigning to this?

#2 @modemlooper
14 years ago

$bp->bp_nav['messages']['name'] = 'new_name' ;'

#3 @DJPaul
14 years ago

I believe you will need to add the message count to this string (for example) when you set it. BP doesn't process a %s placeholder and replace it after the fact.

#4 @DJPaul
14 years ago

modemlooper, did you try this with %s?

#5 @modemlooper
14 years ago

does not work. the tab text and count needs some sort of separation. currently it's pushed as one string. New item in array 'count' when registering nav items?

        $count = messages_get_unread_count();

		$man_nav[] = array(
			'name'            => __( 'Inbox', 'buddypress' ),
			'slug'            => 'inbox',
			'parent_url'      => $messages_link,
			'parent_slug'     => $this->slug,
			'screen_function' => 'messages_screen_inbox',
			'position'        => 10,
			'count'        => $count,
			'user_has_access' => bp_is_my_profile()
		);


Version 4, edited 14 years ago by modemlooper (previous) (next) (diff)

#6 @modemlooper
14 years ago

  • Keywords close added
  • Resolution set to invalid
  • Severity changed from normal to trivial
  • Status changed from new to closed

closing this, it's not that important and as I pointed out in code above a work around .

#7 @johnjamesjacoby
13 years ago

  • Component changed from Core to Messaging
  • Milestone Awaiting Review deleted
Note: See TracTickets for help on using tickets.