bp_get_the_topic_post_edit_text
Filters the text to edit when editing a post.
Description
Parameters (1)
- 0. $esc_attr (string) =>
esc_attr( $post->post_text )
- The text to edit when editing a post.
Usage
- To run the hook, copy the example below.
- $esc_attr = apply_filters( 'bp_get_the_topic_post_edit_text', $esc_attr );
- if ( !empty( $esc_attr ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the bp_get_the_topic_post_edit_text callback
- function filter_bp_get_the_topic_post_edit_text( $esc_attr ) {
- // make filter magic happen here...
- return $esc_attr;
- };
- // add the filter
- add_filter( 'bp_get_the_topic_post_edit_text', 'filter_bp_get_the_topic_post_edit_text', 10, 1 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'bp_get_the_topic_post_edit_text', 'filter_bp_get_the_topic_post_edit_text', 10, 1 );
Defined (1)
The filter is defined in the following location(s).
- /bp-forums/bp-forums-template.php
- return apply_filters( 'bp_get_the_topic_post_edit_text', esc_attr( $post->post_text ) );