bp_get_the_thread_message_content()
Get the content of the current message in the loop.
Description
Return
(string)
Source
File: bp-messages/bp-messages-template.php
function bp_get_the_thread_message_content() {
global $thread_template;
$content = $thread_template->message->message;
// If user was deleted, mark content as deleted.
if ( false === bp_core_get_core_userdata( bp_get_the_thread_message_sender_id() ) ) {
$content = esc_html__( '[deleted]', 'buddyboss' );
}
/**
* Filters the content of the current message in the loop.
*
* @since BuddyPress 1.1.0
*
* @param string $message The content of the current message in the loop.
*/
return apply_filters( 'bp_get_the_thread_message_content', $content );
}
Changelog
| Version | Description |
|---|---|
| BuddyPress 1.1.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.