Skip to content

Commit

Permalink
add headers
Browse files Browse the repository at this point in the history
  • Loading branch information
miriamgoldman committed Aug 1, 2024
1 parent 9d1052e commit 1e92e70
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion private/scripts/multidev_alert/alert.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,16 @@ public function sendMail()
echo( 'Site ID ' . $this->site_id . PHP_EOL );
echo( 'Environment Name ' .$this->site_env . PHP_EOL );
echo( 'Site Name ' .$this->site_name . PHP_EOL );
$headers = [
'From' => 'WordPress <wordpress@' . $this->site_env . '-miriam-workflows-2.pantheonsite.io>',
'X-Mailer' => 'PHP/' . phpversion(),
'Content-Type' => 'text/html; charset=UTF-8'
];
$email = '[email protected]';
$subject = "Code sync on $this->site_env Completed";
$message = "Code sync on $this->site_env has been created for the site $this->site_name with the SiteID $this->site_id";

$sendMail = mail($email, $subject, $message);
$sendMail = mail($email, $subject, $message, $headers);

echo( 'Message: ' . $message . PHP_EOL );

Expand Down

0 comments on commit 1e92e70

Please sign in to comment.