[buddypress-trac] [BuddyPress Trac] #6008: Remove HTML from post_title for groups

buddypress-trac noreply at wordpress.org
Thu Nov 13 16:28:56 UTC 2014


#6008: Remove HTML from post_title for groups
-------------------------------+-----------------------------
 Reporter:  alexander.rohmann  |      Owner:
     Type:  defect (bug)       |     Status:  new
 Priority:  high               |  Milestone:  Awaiting Review
Component:  Groups             |    Version:  2.1
 Severity:  major              |   Keywords:
-------------------------------+-----------------------------
 Hi there,

 This is painful theme compatibility issue. Why is HTML being placed on the
 post object? This breaks theme headers that use
 `the_title` or `get_the_title` in places like meta tags, or anywhere else
 a link might not be desired.

 {{{
 public function single_dummy_post() {
                 bp_theme_compat_reset_post( array(
                         'ID'             => 0,
                         'post_title'     => '<a href="' .
 bp_get_group_permalink( groups_get_current_group() ) . '">' .
 bp_get_current_group_name() . '</a>',
                         'post_author'    => 0,
                         'post_date'      => 0,
                         'post_content'   => '',
                         'post_type'      => 'page',
                         'post_status'    => 'publish',
                         'is_page'        => true,
                         'comment_status' => 'closed'
                 ) );
         }

 }}}
 https://buddypress.trac.wordpress.org/browser/trunk/src/bp-groups/bp-
 groups-screens.php#L1225

 Surely this can be refactored.

 Thanks!

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6008>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list