当前位置: 首页>>代码示例>>PHP>>正文


PHP htmlMimeMail::SetSubject方法代码示例

本文整理汇总了PHP中htmlMimeMail::SetSubject方法的典型用法代码示例。如果您正苦于以下问题:PHP htmlMimeMail::SetSubject方法的具体用法?PHP htmlMimeMail::SetSubject怎么用?PHP htmlMimeMail::SetSubject使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在htmlMimeMail的用法示例。


在下文中一共展示了htmlMimeMail::SetSubject方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: htmlMimeMail

 		echo '<p>' . _('There were no transactions to print in the range selected');
 		include('includes/footer.inc');
 		exit;
 	}*/
 if (isset($_GET['Email'])) {
     //email the invoice to address supplied
     include 'includes/header.inc';
     include 'includes/htmlMimeMail.php';
     $mail = new htmlMimeMail();
     $filename = $_SESSION['reports_dir'] . '/Invoice.pdf';
     $fp = fopen($_SESSION['reports_dir'] . '/Invoice.pdf', 'wb');
     fwrite($fp, $pdfcode);
     fclose($fp);
     $attachment = $mail->getFile($filename);
     $mail->setText(_('Please find attached') . ' ' . $InvOrCredit . ' ' . $_GET['FromTransNo']);
     $mail->SetSubject($InvOrCredit . ' ' . $_GET['FromTransNo']);
     $mail->addAttachment($attachment, $filename, 'application/pdf');
     $mail->setFrom($_SESSION['CompanyRecord']['coyname'] . ' <' . $_SESSION['CompanyRecord']['email'] . '>');
     $result = $mail->send(array($_GET['Email']));
     unlink($filename);
     //delete the temporary file
     $title = _('Emailing') . ' ' . $InvOrCredit . ' ' . _('Number') . ' ' . $FromTransNo;
     include 'includes/header.inc';
     echo "<p>{$InvOrCredit} " . _('number') . ' ' . $_GET['FromTransNo'] . ' ' . _('has been emailed to') . ' ' . $_GET['Email'];
     include 'includes/footer.inc';
     exit;
 } else {
     header('Content-type: application/pdf');
     header('Content-Length: ' . $len);
     header('Content-Disposition: inline; filename=Customer_trans.pdf');
     header('Expires: 0');
开发者ID:bodi000,项目名称:weberp-cvs,代码行数:31,代码来源:PrintCustTrans.php

示例2: htmlMimeMail

     /* end of check to see that there was an invoice record to print */
     $FromTransNo++;
 }
 /* end loop to print invoices */
 /* Put the transaction number back as would have been incremented by one after last pass */
 $FromTransNo--;
 if (isset($_GET['Email'])) {
     //email the invoice to address supplied
     include 'includes/header.inc';
     include 'includes/htmlMimeMail.php';
     $FileName = $_SESSION['reports_dir'] . '/' . $_SESSION['DatabaseName'] . '_' . $InvOrCredit . '_' . $FromTransNo . '.pdf';
     $pdf->Output($FileName, 'F');
     $mail = new htmlMimeMail();
     $Attachment = $mail->getFile($FileName);
     $mail->setText(_('Please find attached') . ' ' . $InvOrCredit . ' ' . $FromTransNo);
     $mail->SetSubject($InvOrCredit . ' ' . $FromTransNo);
     $mail->addAttachment($Attachment, $FileName, 'application/pdf');
     if ($_SESSION['SmtpSetting'] == 0) {
         $mail->setFrom($_SESSION['CompanyRecord']['coyname'] . ' <' . $_SESSION['CompanyRecord']['email'] . '>');
         $result = $mail->send(array($_GET['Email']));
     } else {
         $result = SendmailBySmtp($mail, array($_GET['Email']));
     }
     unlink($FileName);
     //delete the temporary file
     $Title = _('Emailing') . ' ' . $InvOrCredit . ' ' . _('Number') . ' ' . $FromTransNo;
     include 'includes/header.inc';
     echo '<p>' . $InvOrCredit . ' ' . _('number') . ' ' . $FromTransNo . ' ' . _('has been emailed to') . ' ' . $_GET['Email'];
     include 'includes/footer.inc';
     exit;
 } else {
开发者ID:fgaudenzi,项目名称:webERP-bootstrap,代码行数:31,代码来源:PrintCustTrans.php

示例3: array

and an array of the receipients */
/*The following three variables need to be modified for the report - the company database to use and the receipients */
/*The Sales report to send */
$_GET['ReportID'] = 2;
/*The company database to use */
$DatabaseName = 'kwamojademo';
/*The people to receive the emailed report */
$Recipients = array('"Root" <root@localhost>', '"' . _('someone else') . '" <someoneelese@sowhere.com>');
$AllowAnyone = true;
include 'includes/session.inc';
include 'includes/ConstructSQLForUserDefinedSalesReport.inc';
include 'includes/PDFSalesAnalysis.inc';
include 'includes/htmlMimeMail.php';
$mail = new htmlMimeMail();
if ($Counter > 0) {
    /* the number of lines of the sales report is more than 0  ie there is a report to send! */
    $pdfcode = $pdf->output();
    $fp = fopen($_SESSION['reports_dir'] . '/SalesReport.pdf', 'wb');
    fwrite($fp, $pdfcode);
    fclose($fp);
    $attachment = $mail->getFile($_SESSION['reports_dir'] . '/SalesReport.pdf');
    $mail->setText(_('Please find herewith sales report'));
    $mail->SetSubject(_('Sales Analysis Report'));
    $mail->addAttachment($attachment, 'SalesReport.pdf', 'application/pdf');
    $mail->setFrom($_SESSION['CompanyRecord']['coyname'] . '<' . $_SESSION['CompanyRecord']['email'] . '>');
    $result = $mail->send($Recipients);
} else {
    $mail->setText(_('Error running automated sales report number') . ' ' . $ReportID);
    $mail->setFrom($_SESSION['CompanyRecord']['coyname'] . '<' . $_SESSION['CompanyRecord']['email'] . '>');
    $result = $mail->send($Recipients);
}
开发者ID:BackupTheBerlios,项目名称:kwamoja,代码行数:31,代码来源:MailSalesReport.php

示例4: fclose

         $NoLines = $LineNumber;
     }
     if ($LineDetails['section'] == 'Summary' and $LastLine == 'Detail') {
         $MsgLineText = $LineDetails['linetext'];
         include 'includes/EDIVariableSubstitution.inc';
     }
 }
 /*end while there are message lines to parse and substitute vbles for */
 fclose($fp);
 /*close the file at the end of each transaction */
 DB_query("UPDATE debtortrans SET EDISent=1 WHERE ID=" . $TransDetails['id']);
 /*Now send the file using the customer transport */
 if ($CustDetails['editransport'] == 'email') {
     $mail = new htmlMimeMail();
     $attachment = $mail->getFile("EDI_INV_" . $TransNo . ".txt");
     $mail->SetSubject('EDI Invoice/Credit Note ' . $TransNo);
     $mail->addAttachment($attachment, 'EDI_INV_' . $TransNo . '.txt', 'application/txt');
     if ($_SESSION['SmtpSetting'] == 0) {
         $mail->setFrom($_SESSION['CompanyRecord']['coyname'] . '<' . $_SESSION['CompanyRecord']['email'] . '>');
         $MessageSent = $mail->send(array($CustDetails['ediaddress']));
     } else {
         $MessageSent = SendmailBySmtp($mail, array($CustDetails['ediaddress']));
     }
     if ($MessageSent == True) {
         echo '<BR><BR>';
         prnMsg(_('EDI Message') . ' ' . $TransNo . ' ' . _('was sucessfully emailed'), 'success');
     } else {
         echo '<BR><BR>';
         prnMsg(_('EDI Message') . ' ' . $TransNo . _('could not be emailed to') . ' ' . $CustDetails['ediaddress'], 'error');
     }
 } else {
开发者ID:fgaudenzi,项目名称:webERP-bootstrap,代码行数:31,代码来源:EDISendInvoices_Reece.php


注:本文中的htmlMimeMail::SetSubject方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。