Make WordPress Core

Opened 3 years ago

Closed 3 years ago

#52979 closed enhancement (duplicate)

Custom names for attachment files over wp_mail function

Reported by: martinkovac's profile martin.kovac Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Mail Keywords:
Focuses: Cc:



currently wp_mail function doesn't support to send attachments with custom names. It has using PHPMailer and this code

$phpmailer->addAttachment( $attachment )

PHPMailer addAttachment function support to send attachment with custom name as second paramater.

  $name = '',
  $encoding = self::ENCODING_BASE64,
  $type = '',
  $disposition = 'attachment'

It should be fine if $attachment in wp_mail function will have this option too.


Change History (1)

#1 @ocean90
3 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed
  • Type changed from feature request to enhancement
  • Version 5.7 deleted

Hello @martinkovac, welcome to WordPress Trac!

Thanks for the ticket. We're already tracking the request in #28407 therefore I'm going to close the ticket as a duplicate.

Note: See TracTickets for help on using tickets.