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


PHP Email::SetHtmlContent方法代码示例

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


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

示例1: Email

	O Resultado da importação do arquivo foi:<br><br>
	Quantidade de liberados para faturamento: ' . $cont_liberado . '<br>
	Mensagens de erro: ' . $cont_erro . '<br>
	<ul>' . $mail_mensagem . '</ul><br><br>
	Att,<br>
	Equipe Cartório Postal<br>
	';
//** you can still specify custom headers as long as you use the constant
//** 'EmailNewLine' to separate multiple headers.
$CustomHeaders = '';
//** create the new email message. All constructor parameters are optional and
//** can be set later using the appropriate property.
$message = new Email($Recipiant, $Sender, $Subject, $CustomHeaders);
$message->Cc = $Cc;
$message->Bcc = $Bcc;
// $text=$row[5];
// $html=$row[5];
//$content=$content;
$message->SetHtmlContent($html);
$pathToServerFile = "attachments/{$at['1']}/{$at['2']}";
//** attach this very PHP script.
$serverFileMimeType = 'multipart/mixed';
//** this PHP file is plain text.
//** attach the given file to be sent with this message. ANy number of
//** attachments can be associated with an email message.
//** NOTE: If the file path does not exist or cannot be read by PHP the file
//** will not be sent with the email message.
$message->Send();
echo '<h1><a href="pedido.php">Clique aqui para voltar</a></h1></div>';
require 'footer.php';
开发者ID:tricardo,项目名称:CartorioPostal_old,代码行数:30,代码来源:pedido_import_result.php

示例2: PedidoDAO

<?php

require_once "../includes/maladireta/config.inc.php";
require_once "../includes/maladireta/class.Email.php";
$pedidoDAO = new PedidoDAO();
$pedidos = $pedidoDAO->listaAtrasados(date('Y-m-d'), date('Y-m-d'));
$pedidos_email = array();
foreach ($pedidos as $p) {
    $pedidos_email[$p->id_usuario][] = $p;
}
foreach ($pedidos_email as $id_usuario => $pedidos) {
    $mensagem = '<h1>Atraso de pedidos</h1>';
    $mensagem .= '<ul>';
    foreach ($pedidos as $p) {
        $mensagem .= '<li>' . $p->id_pedido . "/" . $p->ordem . '</li>';
    }
    $mensagem .= '</ul><br><br>Essa é uma mensagem automática e não precisa ser respondida';
    $message = new Email($p->email, "Cartório Postal <contato@cartoriopostal.com.br>", "Atraso de Pedidos", '');
    $message->SetHtmlContent($mensagem);
    $pathToServerFile = "attachments/{$at['1']}/{$at['2']}";
    //** attach this very PHP script.
    $message->Send();
}
echo '<br>Comunicados de atraso enviados com sucesso!<br>';
开发者ID:tricardo,项目名称:CartorioPostal_old,代码行数:24,代码来源:cron_pedido_atrasado_aviso.php

示例3: FinanceiroDAO

<?php

ini_set('max_execution_time', '0');
require "../model/Database.php";
require "../includes/funcoes.php";
require "../includes/global.inc.php";
$financeiroDAO = new FinanceiroDAO();
$financeiroDAO->replaceFinanceiroFin();
require_once "../includes/maladireta/class.Email.php";
$message = new Email('erick.melo@softfox.com.br', 'erick.melo@softfox.com.br', 'Teste', $CustomHeaders);
$message->Cc = '';
$message->SetHtmlContent('Fim com Sucesso');
$message->Send();
echo '<pre>Fim</pre>';
开发者ID:tricardo,项目名称:CartorioPostal_old,代码行数:14,代码来源:cron_financeiro.php

示例4: date

    echo "\n" . $e->id_empresa . " => " . $e->fantasia . " \t::\t ";
    $pedidos = $pedidoDAO->listarConfirmacaoPendente($e->id_empresa);
    $funcionarios = $usuarioDAO->listarPorDepartamentoEmpresa($e->id_empresa, 2, true);
    if (count($pedidos) > 0) {
        $to2 = '';
        $subject = 'pedidos cancelados em ' . date("d/m/Y");
        $body = '<h3>' . $subject . '</h3>';
        $body .= '<ul>';
        foreach ($pedidos as $pedido) {
            $body .= '<li>' . $pedido->id_pedido . ' / ' . $pedido->ordem . ' </li>';
            $p->status = 'cancelado';
            print_r($p);
            $pedidoAlertaDAO->inserir($p);
            //			$pedidoDAO->cancelaAutomaticamente($p);
        }
        $body .= '</ul>';
        echo count($pedidos);
        foreach ($funcionarios as $i => $f) {
            $to2 .= $i != 0 ? ',' . $f->email : $f->email;
        }
        $from = $to = 'caio.nardi@cartoriopostal.com.br';
        $message = new Email($to, $from, $subject, '');
        $message->SetHtmlContent($body);
        if ($message->Send()) {
            echo ' email enviado!';
        } else {
            echo ' erro ao enviar o email !';
        }
    }
}
echo '</pre>';
开发者ID:tricardo,项目名称:CartorioPostal_old,代码行数:31,代码来源:cron_alerta_cancela_pedido.php

示例5: Email

        $message->Bcc = $Bcc;
        $message->SetHtmlContent($html . '<br><br>' . $email_franquia);
        $pathToServerFile = "attachments/{$at['1']}/{$at['2']}";
        //** attach this very PHP script.
        $serverFileMimeType = 'multipart/mixed';
        //** this PHP file is plain text.
        //** attach the given file to be sent with this message. ANy number of
        //** attachments can be associated with an email message.
        //** NOTE: If the file path does not exist or cannot be read by PHP the file
        //** will not be sent with the email message.
        $message->Send();
        $Recipiant = 'erick.melo@cartoriopostal.com.br';
        $message = new Email($Recipiant, $Sender, $Subject, $CustomHeaders);
        $message->Cc = $Cc;
        $message->Bcc = $Bcc;
        $message->SetHtmlContent($html . '<br><br>' . $email_franquia);
        $pathToServerFile = "attachments/{$at['1']}/{$at['2']}";
        //** attach this very PHP script.
        $serverFileMimeType = 'multipart/mixed';
        //** this PHP file is plain text.
        //** attach the given file to be sent with this message. ANy number of
        //** attachments can be associated with an email message.
        //** NOTE: If the file path does not exist or cannot be read by PHP the file
        //** will not be sent with the email message.
        $message->Send();
        $done = 1;
    } else {
        echo $erro;
    }
}
if ($errors) {
开发者ID:tricardo,项目名称:CartorioPostal_old,代码行数:31,代码来源:comunicado1.php

示例6: replaceExtraParams

 $Bcc = '';
 $Subject = replaceExtraParams($mysql, $table_prefix, "{$defaultname}", $row[4], $r[0]);
 $CustomHeaders = '';
 //** create the new email message. All constructor parameters are optional and
 //** can be set later using the appropriate property.
 $message = new Email($Recipiant, $Sender, $Subject, $CustomHeaders);
 $message->Cc = $Cc;
 $message->Bcc = $Bcc;
 if ($row[8] == "1") {
     $final_str = $disp_str . $final_str;
     $alt_content = $row[17];
     $alt_content = str_replace("{UNSUBSCRIBE-LINK}", $lnk, $alt_content);
     $alt_content = str_replace("{EMAIL}", $toemail, $alt_content);
     $alt_content = replaceExtraParams($mysql, $table_prefix, "{$defaultname}", $alt_content, $r[0]);
     $message->SetTextContent($alt_content);
     $message->SetHtmlContent($final_str);
 } else {
     $message->SetTextContent($final_str);
 }
 if ($smtpmailer == 1 && $flag_var == 1) {
     $mail = new PHPMailer(true);
     //$mail->SMTPDebug  = 2;                     // enables SMTP debug information (for testing)
     $mail->IsSMTP();
     // set mailer to use SMTP
     $mail->Host = $smtp_host;
     // specify SMTP mail server
     $mail->Port = $smtp_port;
     // specify SMTP Port
     $mail->SMTPAuth = $smtp_auth;
     // turn on SMTP authentication
     $mail->Username = $smtp_user;
开发者ID:Maxlander,项目名称:shixi,代码行数:31,代码来源:cron.php


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