diff --git a/src/bp-xprofile/bp-xprofile-admin.php b/src/bp-xprofile/bp-xprofile-admin.php
index 1fb255a..785177e 100644
a
|
b
|
function xprofile_admin_screen( $message = '', $type = 'error' ) { |
114 | 114 | |
115 | 115 | <li id="group_<?php echo esc_attr( $group->id ); ?>"> |
116 | 116 | <a href="#tabs-<?php echo esc_attr( $group->id ); ?>" class="ui-tab"> |
117 | | <?php echo esc_attr( $group->name ); ?> |
| 117 | <?php echo esc_attr( apply_filters( 'bp_get_the_profile_group_name', $group->name ) ); ?> |
118 | 118 | |
119 | 119 | <?php if ( !$group->can_delete ) : ?> |
120 | 120 | <?php _e( '(Primary)', 'buddypress'); ?> |
… |
… |
function xprofile_admin_screen( $message = '', $type = 'error' ) { |
130 | 130 | <?php if ( !empty( $groups ) ) : foreach ( $groups as $group ) : ?> |
131 | 131 | |
132 | 132 | <noscript> |
133 | | <h3><?php echo esc_attr( $group->name ); ?></h3> |
| 133 | <h3><?php echo esc_attr( apply_filters( 'bp_get_the_profile_group_name', $group->name ) ); ?></h3> |
134 | 134 | </noscript> |
135 | 135 | |
136 | 136 | <div id="tabs-<?php echo esc_attr( $group->id ); ?>" class="tab-wrapper"> |
… |
… |
function xprofile_admin_screen( $message = '', $type = 'error' ) { |
164 | 164 | |
165 | 165 | <?php if ( ! empty( $group->description ) ) : ?> |
166 | 166 | |
167 | | <p><?php echo esc_html( $group->description ); ?></p> |
| 167 | <p><?php echo esc_html( apply_filters( 'bp_get_the_profile_group_description', $group->description ) ); ?></p> |
168 | 168 | |
169 | 169 | <?php endif; ?> |
170 | 170 | |
171 | 171 | <fieldset id="<?php echo esc_attr( $group->id ); ?>" class="connectedSortable field-group"> |
172 | | <legend class="screen-reader-text"><?php printf( esc_html__( 'Fields for "%s" Group', 'buddypress' ), $group->name ); ?></legend> |
| 172 | <legend class="screen-reader-text"><?php printf( esc_html__( 'Fields for "%s" Group', 'buddypress' ), apply_filters( 'bp_get_the_profile_group_name', $group->name ) ); ?></legend> |
173 | 173 | |
174 | 174 | <?php |
175 | 175 | |
diff --git a/src/bp-xprofile/bp-xprofile-filters.php b/src/bp-xprofile/bp-xprofile-filters.php
index 7918dd7..55d6e1e 100644
a
|
b
|
add_filter( 'xprofile_filtered_data_value_before_save', 'trim', 2 ); |
59 | 59 | add_filter( 'xprofile_group_name_before_save', 'wp_filter_kses' ); |
60 | 60 | add_filter( 'xprofile_group_description_before_save', 'wp_filter_kses' ); |
61 | 61 | |
| 62 | add_filter( 'xprofile_group_name_before_save', 'stripslashes' ); |
| 63 | add_filter( 'xprofile_group_description_before_save', 'stripslashes' ); |
| 64 | |
62 | 65 | // Save fields |
63 | 66 | add_filter( 'xprofile_field_name_before_save', 'wp_filter_kses' ); |
64 | 67 | add_filter( 'xprofile_field_type_before_save', 'wp_filter_kses' ); |
65 | 68 | add_filter( 'xprofile_field_description_before_save', 'wp_filter_kses' ); |
66 | 69 | add_filter( 'xprofile_field_order_by_before_save', 'wp_filter_kses' ); |
| 70 | |
67 | 71 | add_filter( 'xprofile_field_is_required_before_save', 'absint' ); |
68 | 72 | add_filter( 'xprofile_field_field_order_before_save', 'absint' ); |
69 | 73 | add_filter( 'xprofile_field_option_order_before_save', 'absint' ); |