[英]Newsletter Html email
我准备了一份时事通讯,其中包含一些编辑文本区域和一些默认文本。 我的新闻通讯的用户可以在文本区域中编辑文本,之后单击预览按钮时可以保存已编辑的文本。在此页面中,将显示所有使用PHP($ _POST [])编辑的文本。 单击SendNewsLetter按钮时,会发送邮件,但其中没有任何文本,就像使用PHP来显示文本一样。 有没有其他替代方法可以在邮件正文中显示动态内容。 在此先感谢,请帮帮我。
以下是无法在电子邮件正文中使用的php代码。 在预览中,它可以正常显示。
<table cellspacing="0" cellpadding="0" border="1" width="300px" height="auto" >
<tr><td><?php echo set_value('input1',$_POST['input1']); ?></td></tr>
</table>
这是我的sendemail()
public function newsemail(){
$this->load->library('email');
$config['mailtype'] = 'html';
$header = $this->load->view('index/news1','',true);
$this->email->initialize($config);
$this->email->from('info@xyz.net', 'xyz Consulting');
$this->email->reply_to('info@xyz.net','xyz Consulting');
$this->email->to('mahboob@gmail.com');
//$this->email->cc('mehboob029@gmail.com');
$this->email->bcc('xyz@gmail.com');
$this->email->subject('Newsletter');
$this->email->message( $header );
$mail = $this->email->send();
它取决于您加载的库。
有HTML内容或文本或正文而不是消息的选项。
查看您的查看功能。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.