Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danielpotthast/d0c6d28d98deccd256d22c35ce4e8d64 to your computer and use it in GitHub Desktop.
Save danielpotthast/d0c6d28d98deccd256d22c35ce4e8d64 to your computer and use it in GitHub Desktop.
<?php
class Newsletter
{
private $mailer;
public function __construct()
{
$this->mailer = new Mailer('news@demo.de','Demo News','Reply-To: reply@demo.de');
}
public function send($recipients, $subject, $message) {
foreach ($recipients as $to) {
$this->mailer->send($to, $subject, $message);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment