Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Mail: allow custom attachment filenames in
wp_mail()
.
Previous to this change, attachment filenames in outgoing emails could only ever be derived from their paths (passed in as a numerically indexed array of `$attachments`). This changeset adds support for passing an associative `$attachments` array, where the key strings will be used as filenames instead. Includes 2 new unit tests to ensure both array formats continue to work as intended. Props johnjamesjacoby, ritteshpatel, swissspidy, syntaxart. Fixes #28407. Built from https://develop.svn.wordpress.org/trunk@55030 git-svn-id: http://core.svn.wordpress.org/trunk@54563 1a063a9b-81f0-0310-95a4-ce76da25c4cd
- Loading branch information