Magento通讯未发布 [英] Magento newsletter not posting
问题描述
我希望主页上有新闻通讯.我找到了以下代码,这些代码已复制到内容"标签中.
I wish to have a newsletter on my home page. I found the following code, which I have copied into my "Content" tab.
{{block type="core/template" template="newsletter/subscribe.phtml"}}
这在我的页面上呈现,但是我找不到响应.也就是说,收据不会输入到新闻稿部分.它似乎没有张贴任何地方.这是产生的HTML.
This is rendered on my page, however I cannot find the response. That is, the receipts are not entered into the newsletter section. It doesn't seem to post anywhere. Here is the HTML produced.
<form action="" method="post" id="newsletter-validate-detail">
<div class="block-content">
<label for="newsletter">Sign Up for Our Newsletter:</label>
<div class="input-box">
<input type="text" name="email" id="newsletter" title="Sign up for our newsletter" class="input-text required-entry validate-email" />
</div>
<div class="actions">
<button type="submit" title="Subscribe" class="button"><span><span>Subscribe</span></span></button>
</div>
</div>
</form>
<script type="text/javascript">
//<![CDATA[
var newsletterSubscriberFormDetail = new VarienForm('newsletter-validate-detail');
//]]>
</script>
推荐答案
您需要在阻止类型时使用newsletter/subscribe
,因为core/template
没有getFormActionUrl()
方法,该方法返回用于提交新闻通讯订阅表单的url.
You need to use newsletter/subscribe
as you block type because core/template
doesn't have getFormActionUrl()
method, which returns url for submitting newsletter subscription form.
在CMS页面中使用以下代码:
Use this code inside of your CMS page:
{{block type="newsletter/subscribe" template="newsletter/subscribe.phtml"}}
这篇关于Magento通讯未发布的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!