Skip to:
Content

BuddyPress.org

Ticket #2404: 2404.001.diff

File 2404.001.diff, 1.7 KB (added by cnorris23, 16 years ago)
  • bp-core/bp-core-signup.php

     
    532532function bp_core_signup_send_validation_email( $user_id, $user_email, $key ) {
    533533        $activate_url = bp_get_activation_page() ."?key=$key";
    534534        $activate_url = clean_url( $activate_url );
    535         $admin_email = get_site_option( "admin_email" );
    536535
    537         if ( empty( $admin_email ) )
    538                 $admin_email = 'noreply@' . $_SERVER['SERVER_NAME'];
    539 
    540         $from_name = ( '' == get_option( 'blogname' ) ) ? 'BuddyPress' : wp_specialchars( get_option( 'blogname' ) );
    541         $message_headers = "MIME-Version: 1.0\n" . "From: \"{$from_name}\" <{$admin_email}>\n" . "Content-Type: text/plain; charset=\"" . get_option( 'blog_charset' ) . "\"\n";
    542536        $message = sprintf( __( "Thanks for registering! To complete the activation of your account please click the following link:\n\n%s\n\n", 'buddypress' ), $activate_url );
    543537        $subject = '[' . $from_name . '] ' . __( 'Activate Your Account', 'buddypress' );
    544538
    545539        /* Send the message */
    546         $to = apply_filters( 'bp_core_activation_signup_user_notification_to', $user_email );
    547         $subject = apply_filters( 'bp_core_activation_signup_user_notification_subject', $subject );
    548         $message = apply_filters( 'bp_core_activation_signup_user_notification_message', $message );
     540        $to = apply_filters( 'bp_core_signup_send_validation_email_to', $user_email );
     541        $subject = apply_filters( 'bp_core_signup_send_validation_email_subject', $subject );
     542        $message = apply_filters( 'bp_core_signup_send_validation_email_message', $message, $user_id, $activate_url );
    549543
    550544        wp_mail( $to, $subject, $message, $message_headers );
    551545}