2011-05-23 41 views
0

當有人通過magento中的聯繫表發送給我一封電子郵件時,電子郵件到達時沒有佈局,只顯示整個佈局代碼。電子郵件模板Magento不起作用

應該是什麼這樣的:

二是EEN bericht通過HET contactformulier verstuurd,

  • 名稱:測試
  • 電子郵件: 一月@ jan.nl
  • 電話:nvt

Bericht:

貝斯特meneer/mevrouw 的Het bericht範·德persoon模具接觸 運算heeft genomen


配在這樣的:

<[email protected] 
{"var data.name":"Sender Name", 
"var data.email":"Sender Email", 
"var data.telephone":"Sender Telephone", 
"var data.comment":"Comment"} 
@--> 

<div style="font:11px/1.35em Verdana, Arial, Helvetica, sans-serif;"> 
<table cellspacing="0" cellpadding="0" border="0" width="98%" style="margin-top:10px; font:11px/1.35em Verdana, Arial, Helvetica, sans-serif; margin-bottom:10px;"> 
<tr> 
<td align="center" valign="top"> 
<!-- [ header starts here] --> 
<table cellspacing="0" cellpadding="0" border="0" width="650"> 
<tr> 
<td valign="top"> 
<a href="http://www.mijndomeinnaam.nl/"><img src="http://www.mijndomeinnaam.nl/skin/frontend/default/grayscale/images/logo_email.gif" alt="omschrijving logo" style="margin-bottom:10px;" border="0"/></a></td> 
</tr> 
</table> 

<!-- [ middle starts here] --> 
<table cellspacing="0" cellpadding="0" border="0" width="650"> 
<tr> 
<td valign="top"> 
<p><strong>Er is een bericht verstuurd via het contactformulier</strong>,</p> 
<ul> 
<li>Naam: Jan</li> 
<li>E-mail: [email protected]</li> 
<li>Telefoon: nvt</li> 
</ul> 

<p><strong>Bericht:</strong></p> 
<p>Beste meneer/mevrouw 

Het bericht van de persoon die contact op heeft genomen 

</p> 
</td> 
</tr> 
</table> 

</td> 
</tr> 
</table> 
</div> 

如何解決這個問題?

回答

1

在您的magento數據庫上,轉至'core_email_template'表。在'template_type'列中,更改'2'的值。 (將此應用於所有將此列設置爲'1'的字段或所有要設置爲HTML的字段,而不僅僅是文本)

這樣做,您是說這個電子郵件模板是HTML類型而不是文字。我希望它能起作用。

+0

非常感謝Italo。這是我需要的答案! – Justmac 2011-05-23 19:30:52

2
在應用

/代碼/核心/法師/聯繫人的/ etc/config.xml中

變化

 <email> 
      <contacts_email_email_template translate="label" module="contacts"> 
       <label>Contact Form</label> 
       <file>contact_form.html</file> 
       <type>text</type> 
      </contacts_email_email_template> 
     </email> 

TO

 <email> 
      <contacts_email_email_template translate="label" module="contacts"> 
       <label>Contact Form</label> 
       <file>contact_form.html</file> 
       <type>html</type> 
      </contacts_email_email_template> 
     </email> 

是:HTML的而不是文本

+0

不鼓勵編輯核心代碼,它會被更新覆蓋。 – Walf 2014-08-25 08:25:21