MailChimp,模态,铸造
Posted
技术标签:
【中文标题】MailChimp,模态,铸造【英文标题】:MailChimp, Modal, Foundry 【发布时间】:2020-11-21 09:03:11 【问题描述】:问候:我正在尝试解决为什么当用户单击订阅时 MailChimp 的嵌入代码不起作用。这是该网站的链接,我在其中添加了一个“Newsletter 2”来显示这一点,以及使用“mailto:”代码的原始 Newsletter 按钮,这不是最佳选择,因为它不能与 MailChimp 一起收集用户的电子邮件地址.
这是来自 MailChimp 的代码。任何帮助表示赞赏...谢谢!
使用带有 Foundry 主题和 html 堆栈的 Rapidweaver 来嵌入代码。正在使用的网站:[https://metrospeechlanguagenetwork.org][1]
<!-- Begin Mailchimp Signup Form -->
<link href="//cdn-images.mailchimp.com/embedcode/classic-10_7.css" rel="stylesheet" type="text/css">
<style type="text/css">
#mc_embed_signupbackground:#fff; clear:left; font:14px Helvetica,Arial,sans-serif;
/* Add your own Mailchimp form style overrides in your site stylesheet or in this style block.
We recommend moving this block and the preceding CSS link to the HEAD of your HTML file. */
</style>
<div id="mc_embed_signup">
<form action="https://metrospeechlanguagenetwork.us17.list-manage.com/subscribe/post?u=2be85436fc7ceacf1e36f4a2f&id=dd495cf964" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
<h2>Subscribe</h2>
<div class="indicates-required"><span class="asterisk">*</span> indicates required</div>
<div class="mc-field-group">
<label for="mce-EMAIL">Email Address <span class="asterisk">*</span>
</label>
<input type="email" value="" name="EMAIL" class="required email" id="mce-EMAIL">
</div>
<div id="mce-responses" class="clear">
<div class="response" id="mce-error-response" style="display:none"></div>
<div class="response" id="mce-success-response" style="display:none"></div>
</div> <!-- real people should not fill this in and expect good things - do not remove this or risk form bot signups-->
<div style="position: absolute; left: -5000px;" aria-hidden="true"><input type="text" name="b_2be85436fc7ceacf1e36f4a2f_dd495cf964" tabindex="-1" value=""></div>
<div class="clear"><input type="submit" value="Subscribe" name="subscribe" id="mc-embedded-subscribe" class="button"></div>
</div>
</form>
</div>
<!--End mc_embed_signup-->
<script type="text/javascript">
function form_submit()
document.getElementById("search_form").submit();
function form_reset()
document.getElementById("search_form").reset();
</script>
【问题讨论】:
【参考方案1】:@乔尔·所罗门 您的真实脚本需要位于 Mailchimp.com 网站的 Copy/Paste textarea 中,就在您编写的表单下方。 它的形式是:
<script type='text/javascript' src='//s3.amazonaws.com/downloads.mailchimp.com/js/mc-validate.js'></script>
<script type='text/javascript'>
(function($)
window.fnames = new Array();
window.ftypes = new Array();
fnames[0]='EMAIL';ftypes[0]='email';
fnames[1]='FNAME';ftypes[1]='text';
fnames[2]='LNAME';ftypes[2]='text';
fnames[3]='ADDRESS';ftypes[3]='address';
fnames[4]='PHONE';ftypes[4]='phone';
fnames[5]='BIRTHDAY';ftypes[5]='birthday';
(jQuery));
var $mcj = jQuery.noConflict(true);</script>
<!--End mc_embed_signup-->
【讨论】:
以上是关于MailChimp,模态,铸造的主要内容,如果未能解决你的问题,请参考以下文章