Hi all,
I am still working with PHPRunner 4.2 on several sites and there is no need to change that because all worked fine.
But now I moved one website to another hostingparty and they use SMTP Auth on there servers.
So now my olld script for sending an email after updating a record does't work anymore.
This is my script:
// After record updated
function AfterEdit(&$values, $where, &$oldvalues, &$keys,$inline)
{
// ********** Send conformation email ************
ini_set('SMTP','s161.webhostingserver.nl');
$html = true;
// variables
$to = "you@mail.org";
$from = "me@mail.org";
$website_naam = 'Blahblah';
$subject = "Voortgang Project";
$message = 'Deze mail heeft te maken met project '.$values['Project']. "<br />" . "<br />";
$message .= $values["Voortgang"] . "<br />" . "<br />";
$message .= 'De voortgang vind je hierboven maar misschien zijn er ook aanvullende stukken' . "<br />" . "<br />";
//Headers
$headers = 'From: ' . $website_naam . ' <' . $from . '>' . PHP_EOL;
$headers .= 'X-Mailer: PHP/' . phpversion() . PHP_EOL;
$headers .= 'X-Priority: Normal' . PHP_EOL;
$headers .= ($html) ? 'MIME-Version: 1.0' . PHP_EOL : '';
$headers .= ($html) ? 'Content-type: text/html; charset=iso-8859-1' . PHP_EOL : '';
// Send the message
mail($to, $subject, $message, $headers);
For the SMTP Auth I need to implant the phpmailer codes but I realy don't know how, I read all there is to read but can't get it working.
Can someone help me out here please?
John