如何以编程方式发送电子邮件 Prestashop? [英] How to Send email programatically Prestashop?
本文介绍了如何以编程方式发送电子邮件 Prestashop?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
您好,我正在尝试在模块中的 prestashop 中发送电子邮件但它不起作用.
Hello i am trying to send email in prestashop in module but its not working.
他们有办法做到这一点吗?
Is their any way to do this ?
推荐答案
你应该检查 Mail
类和 Send
方法.
You should check Mail
class and Send
method.
示例:
Mail::Send(
(int) $this->context->language->id,
$this->getTemplate(),
$this->getSubject(),
$this->getTemplateVars(),
$this->getTo(),
$this->getToName(),
$this->getFrom(),
$this->getFromName(),
$this->getFileAttachment(),
$this->isModeSmtp(),
$this->getTemplatePath(),
$this->isDie(),
(int) $this->context->shop->id,
$this->getBcc(),
$this->getReplyTo()
);
您在整个系统中有更多示例.只需搜索邮件::发送"即可在代码中.
You have more examples in entire system. Just search for "Mail::Send" in code.
这篇关于如何以编程方式发送电子邮件 Prestashop?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文