當前位置: 首頁>>代碼示例>>PHP>>正文


PHP cEmail::ReplaceSubject方法代碼示例

本文整理匯總了PHP中cEmail::ReplaceSubject方法的典型用法代碼示例。如果您正苦於以下問題:PHP cEmail::ReplaceSubject方法的具體用法?PHP cEmail::ReplaceSubject怎麽用?PHP cEmail::ReplaceSubject使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在cEmail的用法示例。


在下文中一共展示了cEmail::ReplaceSubject方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: ew_SendNotifyEmail

function ew_SendNotifyEmail($sFn, $sSubject, $sTable, $sKey, $sAction)
{
    // Send Email
    if (EW_SENDER_EMAIL != "" && EW_RECIPIENT_EMAIL != "") {
        $Email = new cEmail();
        $Email->Load($sFn);
        $Email->ReplaceSender(EW_SENDER_EMAIL);
        // Replace Sender
        $Email->ReplaceRecipient(EW_RECIPIENT_EMAIL);
        // Replace Recipient
        $Email->ReplaceSubject($sSubject);
        // Replace Subject
        $Email->ReplaceContent("<!--table-->", $sTable);
        $Email->ReplaceContent("<!--key-->", $sKey);
        $Email->ReplaceContent("<!--action-->", $sAction);
        $Email->Send();
    }
}
開發者ID:BGCX261,項目名稱:zhss-svn-to-git,代碼行數:18,代碼來源:phpfn50.php

示例2: ew_SendTemplateEmail

function ew_SendTemplateEmail($sTemplate, $sSender, $sRecipient, $sCcEmail, $sBccEmail, $sSubject, $arContent)
{
    if ($sSender != "" && $sRecipient != "") {
        $Email = new cEmail();
        $Email->Load($sTemplate);
        $Email->ReplaceSender($sSender);
        // Replace Sender
        $Email->ReplaceRecipient($sRecipient);
        // Replace Recipient
        if ($sCcEmail != "") {
            $Email->AddCc($sCcEmail);
        }
        // Add Cc
        if ($sBccEmail != "") {
            $Email->AddBcc($sBccEmail);
        }
        // Add Bcc
        if ($sSubject != "") {
            $Email->ReplaceSubject($sSubject);
        }
        // Replace subject
        if (is_array($arContent)) {
            foreach ($arContent as $key => $value) {
                $Email->ReplaceContent($key, $value);
            }
        }
        return $Email->Send();
    }
    return FALSE;
}
開發者ID:Razinsky,項目名稱:echaude-com,代碼行數:30,代碼來源:phpfn8.php

示例3: SendEmailOnEdit

 function SendEmailOnEdit(&$rsold, &$rsnew)
 {
     echo $rsold;
     global $Language;
     $sFn = "phptxt/notify.txt";
     $sTable = 'messages';
     $sSubject = $sTable . " " . $Language->Phrase("RecordUpdated");
     $sAction = $Language->Phrase("ActionUpdated");
     // Get key value
     $sKey = "";
     if ($sKey != "") {
         $sKey .= $GLOBALS["EW_COMPOSITE_KEY_SEPARATOR"];
     }
     $sKey .= $rsold['id'];
     $Email = new cEmail();
     $Email->Load($sFn);
     $Email->ReplaceSender(EW_SENDER_EMAIL);
     // Replace Sender
     $Email->ReplaceRecipient(EW_RECIPIENT_EMAIL);
     // Replace Recipient
     $Email->ReplaceSubject($sSubject);
     // Replace Subject
     $Email->ReplaceContent("<!--table-->", $sTable);
     $Email->ReplaceContent("<!--key-->", $sKey);
     $Email->ReplaceContent("<!--action-->", $sAction);
     $Email->Charset = EW_EMAIL_CHARSET;
     $Args = array();
     $Args["rsold"] =& $rsold;
     $Args["rsnew"] =& $rsnew;
     $bEmailSent = FALSE;
     if ($this->Email_Sending($Email, $Args)) {
         $bEmailSent = $Email->Send();
     }
     // Send email failed
     if (!$bEmailSent) {
         $this->setFailureMessage($Email->SendErrDescription);
     }
 }
開發者ID:Ombogo,項目名稱:new_api_chat,代碼行數:38,代碼來源:messagesedit.php


注:本文中的cEmail::ReplaceSubject方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。