<?php
 
  ##############################################################################
 
  #  Project : ABG_SMTPMail                                                    #
 
  #  File    : ABG_SMTP_test.php                                               #
 
  #  V1.0.0 26/03/2006  : Initial                                              #
 
  #  V1.1.0 21/05/2006  : Improvements & fit to new classes                    #
 
  #  V1.1.1 21/05/2006  : Minor bug fixes                                      #
 
  #  (cy)  G. BENABOU / ABG Soft PARIS FRANCE                                  #
 
  #                                                                            #
 
  #  A PHP 4 script to test the ABG_SMTP Classes                               #
 
  #                                                                            #
 
  ##############################################################################
 
 
  // Choose (uncomment) the script you want to use (only one at a a time !!)
 
  //  require ("ABG_SMTP.inc.php");                   // Full features
 
  //  require ("ABG_SMTP_Lite.inc.php");              // Lightened
 
  /*** Definitions ************************************************************/
 
  $server  = "smtp.provider.com";    // SMTP server URL
 
  $login   = "J-Smith";              // Authentification login; blank if not used
 
  $pwd     = "m3d*rez4d";            // Authentification password (if authent.)
 
  $from    = "[email protected]";  // Sender email address
 
 
  // List(comma separated) of recipients (ABG_SMTP.inc.php)
 
  // Unique recipient (ABG_SMTP_Lite .inc.php)
 
  $to      = "[email protected][, [email protected]]";
 
 
  // List(comma separated) of more recipients
 
  // $cc & $bcc used by ABG_SMTP.inc.php only; left for compatibility
 
  $cc      = "[email protected], [email protected]";
 
  $bcc     = "[email protected]";
 
  $subject = "The subject of the message is ...";
 
  $body    = "Here is the body of the message; you can insert \n (newlines) ..";
 
 
  /*** Instantiate object and run **********************************************/
 
  $smtp    = new ABG_SMTPMail($server);
 
 
   // Get the result of the transaction and reports
 
  $Result = $smtp->ob_SendMail( $login, $pwd, $from, $to, $cc, $bcc, $subject, $body);
 
  echo ($smtp->ob_Status);
 
  echo ($Result ? "Message sent succesfully!" : "Error sending message \n $smtp->ob_Error");
 
?>
 
 |