如何将Facebook分享按钮更改为图像? [英] How to Change Facebook Share Button to Image?
本文介绍了如何将Facebook分享按钮更改为图像?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
< div class =fb- share-buttondata-href =https://developers.facebook.com/docs/plugins/data-type =button_count>< / div>
有没有办法更改我喜欢的图像?
我也尝试过链接选项,但仍然似乎没有办法添加自定义图像:
div class =fb-share-buttondata-href =https://developers.facebook.com/docs/plugins/data-type =link>< / div>
解决方案
点击分享按钮,复制地址栏,然后粘贴到下面的URL部分。
< a target =_ blankhref =javascript:window.open 'URL', '标题', '宽度= 500,高度= 300')>
< img src =img.jpg>
< / a>
现在,您可以在标签之间放置任何内容,并点击它将打开共享。
Using an HTML5 code of Facebook share, this gives us the following code:
<div class="fb-share-button" data-href="https://developers.facebook.com/docs/plugins/" data-type="button_count"></div>
Is there a way to change the image that I like?
I also tried the link option but there's still seems no way to add a custom image:
<div class="fb-share-button" data-href="https://developers.facebook.com/docs/plugins/" data-type="link"></div>
解决方案
Click the share button, copy the address bar, and then paste that into the URL section below.
<a target="_blank" href="javascript:window.open('URL','title','width=500,height=300')">
<img src="img.jpg">
</a>
Now you can put anything between to the tags and clicking it will open to share.
这篇关于如何将Facebook分享按钮更改为图像?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文