• Resolved dimendia

    (@dimendia)


    Is it possible to send an automated PM as soon as a new user has registered and has been activated

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Shamim Hasan

    (@shamim51)

    I have put this code in my functions. Before an Update it works but now not.

    ——————–
    add_action( ‘user_register’, ‘fep_cus_user_register_send_messaage’, 10, 1 );

    function fep_cus_user_register_send_messaage( $user_id ){
    if ( $user_id < 1 )
    return;
    if ( ! function_exists( ‘fep_send_message’ ) )
    return;

    // Prepare message data
    $message = array(
    ‘message_title’ => ‘Willkommen ‘ . fep_get_userdata( $user_id, ‘display_name’, ‘id’ ), //change with message title
    ‘message_content’ => ‘Das hier ist dein pers?nliches Postfach auf xxx

    xxx‘, //change with message content
    ‘message_to_id’ => $user_id
    );

    $override = array(
    ‘post_author’ => 1, //change with message sender id
    );

    // Send message
    fep_send_message( $message, $override );
    ————————–

    Any Idea?

    Plugin Author Shamim Hasan

    (@shamim51)

    I have tested this code with latest version and working correctly. Please recheck. If require copy again from above link.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Auto PM’ is closed to new replies.