Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
05/06/2013 12:01:25 AM (13 years ago)
Author:
boonebgorges
Message:

Put widget titles through WP's widget_title filter before assembling markup

This will provide a more predictable way to modify widget titles in the same
way as WP's core widgets.

Fixes #4299

Props magnus78, merty

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-groups/bp-groups-widgets.php

    r6975 r6999  
    4848            $instance['title'] = __( 'Groups', 'buddypress' );
    4949
     50        $title = apply_filters( 'widget_title', $instance['title'] );
     51
    5052        echo $before_widget;
    5153
    52         $title = !empty( $instance['link_title'] ) ? '<a href="' . trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() ) . '">' . $instance['title'] . '</a>' : $instance['title'];
     54        $title = !empty( $instance['link_title'] ) ? '<a href="' . trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() ) . '">' . $title . '</a>' : $title;
    5355
    5456        echo $before_title . $title . $after_title; ?>
Note: See TracChangeset for help on using the changeset viewer.