Ticket #2857: 2857.01.patch
| File 2857.01.patch, 2.3 KB (added by , 11 years ago) |
|---|
-
src/includes/admin/metaboxes.php
25 25 // Forums 26 26 if ( current_user_can( 'publish_forums' ) ) { 27 27 $link = add_query_arg( array( 'post_type' => bbp_get_forum_post_type() ), get_admin_url( null, 'edit.php' ) ); 28 $text = sprintf( _n( '% d Forum', '%dForums', $r['forum_count'], 'bbpress' ), $r['forum_count'] );28 $text = sprintf( _n( '%s Forum', '%s Forums', $r['forum_count'], 'bbpress' ), $r['forum_count'] ); 29 29 $elements[] = '<a href="' . esc_url( $link ) . '" class="bbp-glance-forums">' . esc_html( $text ) . '</a>'; 30 30 } 31 31 32 32 // Topics 33 33 if ( current_user_can( 'publish_topics' ) ) { 34 34 $link = add_query_arg( array( 'post_type' => bbp_get_topic_post_type() ), get_admin_url( null, 'edit.php' ) ); 35 $text = sprintf( _n( '% d Topic', '%dTopics', $r['topic_count'], 'bbpress' ), $r['topic_count'] );35 $text = sprintf( _n( '%s Topic', '%s Topics', $r['topic_count'], 'bbpress' ), $r['topic_count'] ); 36 36 $elements[] = '<a href="' . esc_url( $link ) . '" class="bbp-glance-topics">' . esc_html( $text ) . '</a>'; 37 37 } 38 38 39 39 // Replies 40 40 if ( current_user_can( 'publish_replies' ) ) { 41 41 $link = add_query_arg( array( 'post_type' => bbp_get_reply_post_type() ), get_admin_url( null, 'edit.php' ) ); 42 $text = sprintf( _n( '% d Reply', '%dReplies', $r['reply_count'], 'bbpress' ), $r['reply_count'] );42 $text = sprintf( _n( '%s Reply', '%s Replies', $r['reply_count'], 'bbpress' ), $r['reply_count'] ); 43 43 $elements[] = '<a href="' . esc_url( $link ) . '" class="bbp-glance-replies">' . esc_html( $text ) . '</a>'; 44 44 } 45 45 46 46 // Topic Tags 47 47 if ( bbp_allow_topic_tags() && current_user_can( 'manage_topic_tags' ) ) { 48 48 $link = add_query_arg( array( 'taxonomy' => bbp_get_topic_tag_tax_id(), 'post_type' => bbp_get_topic_post_type() ), get_admin_url( null, 'edit-tags.php' ) ); 49 $text = sprintf( _n( '% d Topic Tag', '%dTopic Tags', $r['topic_tag_count'], 'bbpress' ), $r['topic_tag_count'] );49 $text = sprintf( _n( '%s Topic Tag', '%s Topic Tags', $r['topic_tag_count'], 'bbpress' ), $r['topic_tag_count'] ); 50 50 $elements[] = '<a href="' . esc_url( $link ) . '" class="bbp-glance-topic-tags">' . esc_html( $text ) . '</a>'; 51 51 } 52 52