How to make a Facebook “Like” button that is just a link, not an iFrame?

后端 未结 4 1255
独厮守ぢ
独厮守ぢ 2021-01-07 17:48

I would like to put a \"Like\" button into an email message that it going out to our e-newsletter subscribers. The usual way of embedding a Like button, which uses, an ifram

4条回答
  •  被撕碎了的回忆
    2021-01-07 18:32

    It was never possible to like some site with Facebook "Like" plugin from email for security reasons.

    But sometimes it is difficult to explain it to your boss, who wants something similar that others emails have. If this was your case, you could offer my answer to your management.

    The following code doesn't make you a fan of the page but rather likes the site's home page, and it gives you a Like button and "X people like this. Be the first of your friends."

    If this is what you want, please see the code:

    replace http://eyeclarity.com.au - to your site and if you do not like my like button, replace http://www.4wdaction.com.au/_phpBB/download/file.php?id=68849 with your one

    
        
    
    

    jsfiddle

    aforementioned code will redirect you to a link, that looks like this

    https://www.facebook.com/plugins/like.php?href=http://eyeclarity.com.au&%20%20%20layout=standard&%20%20%20show_faces=false&%20%20%20width=450&%20%20%20action=like&%20%20%20colorscheme=light&
    

    Now, you can try clicking it and see some animation that Facebook is offering.

提交回复
热议问题