]> git.mxchange.org Git - mailer.git/blobdiff - inc/classes/third_party/php_mailer/examples/test_gmail.php
Moved to repository 'core' (not yet done)
[mailer.git] / inc / classes / third_party / php_mailer / examples / test_gmail.php
diff --git a/inc/classes/third_party/php_mailer/examples/test_gmail.php b/inc/classes/third_party/php_mailer/examples/test_gmail.php
deleted file mode 100644 (file)
index 4592efc..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php\r
-\r
-//error_reporting(E_ALL);\r
-error_reporting(E_STRICT);\r
-\r
-date_default_timezone_set('America/Toronto');\r
-\r
-include("class.phpmailer.php");\r
-//include("class.smtp.php"); // optional, gets called from within class.phpmailer.php if not already loaded\r
-\r
-$mail             = new PHPMailer();\r
-\r
-$body             = $mail->getFile('contents.html');\r
-$body             = eregi_replace("[\]",'',$body);\r
-\r
-$mail->IsSMTP();\r
-$mail->SMTPAuth   = true;                  // enable SMTP authentication\r
-$mail->SMTPSecure = "ssl";                 // sets the prefix to the servier\r
-$mail->Host       = "smtp.gmail.com";      // sets GMAIL as the SMTP server\r
-$mail->Port       = 465;                   // set the SMTP port for the GMAIL server\r
-\r
-$mail->Username   = "yourusername@gmail.com";  // GMAIL username\r
-$mail->Password   = "yourpassword";            // GMAIL password\r
-\r
-$mail->AddReplyTo("yourusername@gmail.com","First Last");\r
-\r
-$mail->From       = "name@yourdomain.com";\r
-$mail->FromName   = "First Last";\r
-\r
-$mail->Subject    = "PHPMailer Test Subject via gmail";\r
-\r
-//$mail->Body       = "Hi,<br>This is the HTML BODY<br>";                      //HTML Body\r
-$mail->AltBody    = "To view the message, please use an HTML compatible email viewer!"; // optional, comment out and test\r
-$mail->WordWrap   = 50; // set word wrap\r
-\r
-$mail->MsgHTML($body);\r
-\r
-$mail->AddAddress("whoto@otherdomain.com", "John Doe");\r
-\r
-$mail->AddAttachment("images/phpmailer.gif");             // attachment\r
-\r
-$mail->IsHTML(true); // send as HTML\r
-\r
-if(!$mail->Send()) {\r
-  echo "Mailer Error: " . $mail->ErrorInfo;\r
-} else {\r
-  echo "Message sent!";\r
-}\r
-\r
-?>\r