Skip to content

Instantly share code, notes, and snippets.

@ss23
Created April 11, 2013 09:15
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 ss23/5361923 to your computer and use it in GitHub Desktop.
Save ss23/5361923 to your computer and use it in GitHub Desktop.
<?php
// Email
// To Client
$email = new Email('', $result['Email'], 'You just secured a great deal on StayEatPlay.co.nz', '');
$email->setTemplate('ClientEmail');
$email->populateTemplate(array(
'Name' => $result['Name'],
'StayName' => $deal->StayName,
'EatName' => $deal->EatName,
'PlayName' => $deal->PlayName,
'StayPhone' => $deal->StayPhone,
'UniqueID' => $result['UniqueID'],
'Content' => 'FILL ME IN',
));
$email->sendPlain();
// To Stay
$email = new Email('', $deal->StayEmail, 'Someone has just secured a great deal on StayEatPlay.co.nz', '');
$email->setTemplate('StayEmail');
$email->populateTemplate(array(
'Name' => $result['Name'],
'StayName' => $deal->StayName,
'EatName' => $deal->EatName,
'PlayName' => $deal->PlayName,
'UniqueID' => $result['UniqueID'],
'Content' => 'FILL ME IN',
'ClientEmail' => $result['Email'],
'ClientPhone' => $result['Phone'],
));
$email->sendPlain();
// To StayEatPlay
$email = new Email('', 'deal@info-rotorua.com', 'Someone has just secured a great deal on StayEatPlay.co.nz', '');
$email->setTemplate('InfoRotoruaEmail');
$email->populateTemplate(array(
'Name' => $result['Name'],
'StayName' => $deal->StayName,
'EatName' => $deal->EatName,
'PlayName' => $deal->PlayName,
'UniqueID' => $result['UniqueID'],
'Content' => 'FILL ME IN',
'ClientEmail' => $result['Email'],
'ClientPhone' => $result['Phone'],
));
$email->sendPlain();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment