Reply To: Messages panel


Home Forums Front End PM PRO Messages panel Reply To: Messages panel

#37695
shamim
Keymaster

As this plugin support multiple recipients, showing other users name is little confusing as there may have more than one receiver. If you support to send message to only one receiver then you can follow following approach.

If you want to show other users avatar add following code in your theme’s (child theme you are using one) functions.php

add_filter( 'fep_remove_own_avatar_from_messagebox', '__return_true' );

If you want to show other user name add following code in your theme’s (child theme you are using one) functions.php

add_action( 'fep_message_table_column_content_author', function(){
	$participants = fep_get_participants( fep_get_the_id() );
	foreach( $participants as $participant ) {
		if ( get_current_user_id() != $participant ) {
			?><span class="fep-message-author"><?php echo fep_user_name( $participant ); ?></span><span class="fep-message-date"><?php echo fep_get_the_date( 'mgs_last_reply_time' ); ?></span><?php
			break;
		}
	}
});