Skip to:
Content
Pages
Categories
Search
Top
Bottom

Reply To: customizing bbpress admin links

@robkk

Moderator

you want to change the

links that come up with a topic or reply so that only some show, and others are in a dropdown list.

is that correct?

yes

This also gives you the ability to add a new link

yeah i added the topic favorite link to see if it worked and it did with the ajax too
and also a mark topic as read from the bbpress go to first unread plugin

You’ll also see that this function checks if it is a topic on line 1825

i used this as a filter for the topic admin links

//change admin links displayed
function change_topic_admin_links ($r) {
$r['links'] = apply_filters( 'rw_topic_admin_links', array(
				'edit'  => bbp_get_topic_edit_link ( $r ),
				'reply'  => bbp_get_topic_reply_link ( $r )
				
			), $r['id'] );
return $r['links'] ;
}
add_filter ('bbp_topic_admin_links', 'change_topic_admin_links' ) ;

i tried using this function to post a single admin link for a topic
and also just by replacing return with echo
but i cant seem to get that to work

if ( bbp_is_topic( $r['id'] ) ) {
			return bbp_get_name_of_link();
		}

		if ( !bbp_is_reply( $r['id'] ) ) {
			return bbp_get_name_of_link() ;
		}
Skip to toolbar