2012-07-05 83 views
0

我有一个Drupal的网络应用程序,发出订单时的电子邮件。我们有HTMLMail以便用主题格式化传出消息。目前页眉和页脚正确包装,因为它们应该与图形,但正文文本显示原始的HTML代码。PHP不在电子邮件中呈现HTML

实施例:

<p>We have received your order and one of our representatives will review your information shortly. If you have any questions about this order please call us at (phone). Please reference your reservation number when calling. Here are the details of your order:</p><div class="item-list"><h3>Order Summary</h3><ul><li class="first"><span class="confirmation-label">Confirmation Number:</span> 

等等等等。在邮件模板中,只需执行'echo $ body';打印应包含上述内容的消息。

+0

不熟悉HTMLMail模块,但是......有可能是身体可能应用了错误的文本格式过滤器? – nmc 2012-07-05 19:43:15

回答

1

将主体的内容类型设置为text/html并确保您没有任何代码可以自动转义它。

+0

已经完成了所有这些。 – Kevin 2012-07-05 18:38:00