Skip to:
Content
Pages
Categories
Search
Top
Bottom

Send HTML in messages_new_message()


  • Michael Ritsch
    Participant

    @michaelritsch

    Hi, i didn’t found any fittings solution for my problem, i hope you can help me out.

    I want to send a private message to one single User from my functions.php. This is just a kind of notification. Inside this message, i want to show two links and style it with some html tags like BR and Strong.. simple things…i thought.

    But then i realized that buddypress filters out everything :/

    $message = ‘This is the test<br>more like that.’;
    $args = array( ‘recipients’ => [$user_teacher], ‘sender_id’ => $user_user, ‘subject’ => ‘Anfrage ‘ . mre_get_full_name($user_user), ‘content’ => $message );

    $sending = messages_new_message( $args );

    I tryed to remove the ‘messages_message_content_before_save’ Filter from inside a bp-custom.php file and also inside of my functions.php… but nothing happens.

    Does someone know a solution for this?

    Wp version: 4.9.4
    Bp version: 2.9.3

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.
Skip to toolbar