如何在 HTML 时事通讯中嵌入一个类似 facebook 的按钮?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/5859714/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to embed a facebook like button in a HTML Newsletter?
提问by romain
I would like my readers to like my fan page while reading my newsletter. How to embed the standard iFrame button count at the beginning of my email?
我希望我的读者在阅读我的时事通讯时喜欢我的粉丝页面。如何在我的电子邮件开头嵌入标准 iFrame 按钮计数?
回答by Tom Claus
The standard iframe is imposible to use in email campaigns. But u can fake it a little bit by using the like/share image from Facebook and lik tot the share site.
标准 iframe 无法用于电子邮件活动。但是你可以通过使用来自 Facebook 的喜欢/分享图片和喜欢分享网站来伪造它。
<a href='http://www.facebook.com/share.php?u=http://domain.com'>
<img src='http://domain.com/like.png' alt='Like my site' />
</a>
回答by Joakim Syk
You can add this link:
您可以添加此链接:
http://www.facebook.com/plugins/like.php?href=http://domain.com
http://www.facebook.com/plugins/like.php?href=http://domain.com
Not a beautiful landing page though. It's probably better to link to your own page with the Like button as an IFRAME.
虽然不是一个漂亮的着陆页。使用“赞”按钮作为 IFRAME 链接到您自己的页面可能会更好。
回答by user1429586
So you want to know ‘How to add a ‘Facebook Like Button' to your email template‘. Ever since MailChimp promised to add the functionality to their system we have seen a buzz with people wondering how they do it. This article is a quick and dirty guide to DIY Facebook Like Buttons embedded in email templates. So no matter who your ESP is you can embed a Like Button within your email design.
所以您想知道“如何在您的电子邮件模板中添加‘Facebook 点赞按钮’”。自从 MailChimp 承诺将功能添加到他们的系统后,我们就看到了人们想知道他们是如何做到的。这篇文章是关于嵌入在电子邮件模板中的 DIY Facebook Like 按钮的快速而肮脏的指南。因此,无论您的 ESP 是谁,您都可以在电子邮件设计中嵌入“赞”按钮。
Well to be perfectly honest it really is not that hard, however contrary to what you may have hoped it is not quite seamless and there is no way for it to be. It involves a 2 click process.
老实说,这真的不是那么难,但与您可能希望的相反,它不是完全无缝的,也没有办法做到这一点。它涉及一个 2 单击过程。
The simplest way and the one most likely to work for most users is to use the following code.
最简单的方法也是最有可能对大多数用户有效的方法是使用以下代码。
— The Code —
- 编码 -
<a href="http://www.facebook.com/plugins/like.php? href=http://www.facebook.com/pages/Email-Expert/130177676994892?ref%3Dts&layout=standard&show_faces=true&width=450&action=like&colorscheme=light&height=80 target=">
<img title="Facebook Like Button" src="http://emailexpert.org/dontexist/likebutton.jpg" alt="" />
</a>
—-ends—-
——结束——
Instructions
指示
Change the URL to the page you want ‘liked'
Change the img location and upload your likebutton image.
将 URL 更改为您想要“喜欢”的页面
更改 img 位置并上传您的喜欢按钮图像。