我正在为icici银行支付途径创建新模块。它的工作很好,但在管理员端没有收到任何电子邮件后,完整顺序中的一个问题。我的脚本中包含的代码或函数是什么,可以通过我的管理员电子邮件ID获取电子邮件。
catalog\controller\payment\payeezy.php
页面
$subject = 'Payment Status';
$text = "Dear ".$order_info['firstname']." ".$order_info['lastname']. "\n\n";
$text .= "We have received your order, Thanks for your Ccavenue payment.The transaction was successful.Your payment is authorized.". "\n";
$text .= "The details of the order are below:". "\n\n";
$text .= "Order ID: ".$order_id. "\n";
$text .= "Date Ordered: ".$order_info['date_added']. "\n";
$text .= "Payment Method: ".$order_info['payment_method']. "\n";
$text .= "Shipping Method: ".$order_info['shipping_method']. "\n";
$text .= "Order Total: ".$order_info['total']. "\n\n";
$to = array(1=>$order_info['email'],2=>$this->config->get('config_email'));
$mail = new Mail();
$mail->protocol = $this->config->get('config_mail_protocol');
$mail->parameter = $this->config->get('config_mail_parameter');
$mail->hostname = $this->config->get('config_smtp_host');
$mail->username = $this->config->get('config_smtp_username');
$mail->password = $this->config->get('config_smtp_password');
$mail->port = $this->config->get('config_smtp_port');
$mail->timeout = $this->config->get('config_smtp_timeout');
$mail->setTo($to);
$mail->setFrom($this->config->get('config_email'));
//$mail->setReplyTo($this->request->post['email']);
//$mail->setFrom($this->config->get('config_email'));
$mail->setSender($order_info['store_name']);
$mail->setSubject($subject);
// THIS IS THE IMPORTANT PART
$mail->setText(html_entity_decode($text, ENT_QUOTES, 'UTF-8'));
// END OF IMPORTANT PART
$mail->send();