I've been following this guide to send emails using Amazon SES: http://www.codeproject.com/Articles/786596/How-to-Use-Amazon-SES-to-Send-Email-from-PHP
This worked fine and I was able to send emails. What I want is to also be able to display the name of the sender instead of just the email address when the receiver gets the email.
What I currently have now is:
$msg = array();
$msg['Source'] = "[email protected]";
How can I also add a name to this? I was previously using swiftmailer and this worked with "[email protected]' => 'My Name'". This, however, doesn't work with amazon SES, at least not in my script.
$host = ' email-smtp.us-west-2.amazonaws.com '; $port = 587; // The subject line of the email $subject = 'Amazon SES test (SMTP interface accessed using PHP)'; // The plain-text body of the email $bodyText = "Email Test\r\nThis email was sent through the Amazon SES SMTP interface using the PHPMailer class."; // The ...
On the All metrics tab, choose SES. Choose the dimension name that you entered when you created the configuration set. For example, choose ses:caller-identity. Under the ses:caller-identity column, you'll see the IAM user who sent the test email.
From the navigation pane, under Email Sending, choose SMTP Settings. Choose Create My SMTP Credentials. For IAM User Name, you can accept the default name, or enter a new name. Choose Create.
I figured it out. If anyone has the same issue just format it like in the example below:
$msg['Source'] = "My Name <[email protected]>";
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With