Using the Filter to Change Text

Hi RT team,

Thanks for a great media plugin - the best for BuddyPress!

I read this post to understand how to change the text “Oops !! There’s no media found for the request !!” but I’m afraid I don’t know how to make use of the filter (rtmedia_no_media_found_message_filter).

I understand that it goes in my child theme’s functions.php, but I haven’t been able to determine the syntax.

Can you help me?

Hi @jgwolfensberger,

Put below code in your theme’s functions.php file:

add_filter( 'rtmedia_no_media_found_message_filter', 'custom_no_media_found_message_function' ,10, 1 );
function custom_no_media_found_message_function( $message ) {
    $message = "Custom Message";
    return $message;
}

Thank you so much. Works beautifully!

Hi @jgwolfensberger,

I am glad to hear that your issue is fixed.