Make WordPress Core


Ignore:
Timestamp:
04/01/2017 02:33:59 PM (8 years ago)
Author:
SergeyBiryukov
Message:

Mail: Use correct capitalization for PHPMailer methods in wp_mail().

Props Soean, reidbusi.
Fixes #39702.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/pluggable.php

    r40264 r40363  
    309309
    310310    // Empty out the values that may be set
    311     $phpmailer->ClearAllRecipients();
    312     $phpmailer->ClearAttachments();
    313     $phpmailer->ClearCustomHeaders();
    314     $phpmailer->ClearReplyTos();
     311    $phpmailer->clearAllRecipients();
     312    $phpmailer->clearAttachments();
     313    $phpmailer->clearCustomHeaders();
     314    $phpmailer->clearReplyTos();
    315315
    316316    // From email and name
     
    411411
    412412    // Set to use PHP's mail()
    413     $phpmailer->IsMail();
     413    $phpmailer->isMail();
    414414
    415415    // Set Content-Type and charset
     
    431431    // Set whether it's plaintext, depending on $content_type
    432432    if ( 'text/html' == $content_type )
    433         $phpmailer->IsHTML( true );
     433        $phpmailer->isHTML( true );
    434434
    435435    // If we don't have a charset from the input headers
     
    451451    if ( !empty( $headers ) ) {
    452452        foreach ( (array) $headers as $name => $content ) {
    453             $phpmailer->AddCustomHeader( sprintf( '%1$s: %2$s', $name, $content ) );
     453            $phpmailer->addCustomHeader( sprintf( '%1$s: %2$s', $name, $content ) );
    454454        }
    455455
    456456        if ( false !== stripos( $content_type, 'multipart' ) && ! empty($boundary) )
    457             $phpmailer->AddCustomHeader( sprintf( "Content-Type: %s;\n\t boundary=\"%s\"", $content_type, $boundary ) );
     457            $phpmailer->addCustomHeader( sprintf( "Content-Type: %s;\n\t boundary=\"%s\"", $content_type, $boundary ) );
    458458    }
    459459
     
    461461        foreach ( $attachments as $attachment ) {
    462462            try {
    463                 $phpmailer->AddAttachment($attachment);
     463                $phpmailer->addAttachment($attachment);
    464464            } catch ( phpmailerException $e ) {
    465465                continue;
Note: See TracChangeset for help on using the changeset viewer.