WordPress.org

Make WordPress Core

Ticket #39642: multipart-mime.diff

File multipart-mime.diff, 779 bytes (added by JeffMatson, 4 years ago)

Diff for proposed solution

  • wp-includes/pluggable.php

    diff --git wp-includes/pluggable.php wp-includes/pluggable.php
    index 3e6fbe1..28adbc7 100644
    function wp_mail( $to, $subject, $message, $headers = '', $attachments = array() 
    367367
    368368        // Set mail's subject and body
    369369        $phpmailer->Subject = $subject;
    370         $phpmailer->Body    = $message;
     370
     371        if ( is_array( $message ) ) {
     372                $phpmailer->Body = $message['0'];
     373                $phpmailer->AltBody = $message['1'];
     374        } else {
     375                $phpmailer->Body = $message;
     376        }
    371377
    372378        // Set destination addresses, using appropriate methods for handling addresses
    373379        $address_headers = compact( 'to', 'cc', 'bcc', 'reply_to' );
    function wp_text_diff( $left_string, $right_string, $args = null ) { 
    25062512        return $r;
    25072513}
    25082514endif;
    2509