apply_filters( 'um_restricted_post_content', $content, $post_id, $original_post_content ) → {string}
Filters the restricted post content. Can be used for translations when site is multilingual.
Parameters:
Name | Type | Description |
---|---|---|
$content |
string | Post content prepared from restricted message. |
$post_id |
int | Post ID |
$original_post_content |
string | Original post content. |
- Since:
- 2.8.7
- Source:
Returns:
Maybe changed post content prepared from restricted message.
- Type
- string
Example
function my_restricted_post_content( $content, $post_id, $original_post_content ) {
if ( 111 === $post_id ) {
$content = trim( $content );
}
return $content;
}
add_filter( 'um_restricted_post_content', 'my_restricted_post_content', 10, 3 );