简体   繁体   English

如何始终显示 AddThis 的共享计数器?

[英]How to always show share counter for AddThis?

I am using AddThis to show social media share buttons.我正在使用 AddThis 来显示社交媒体共享按钮。 I have used the "Sharing Buttons" tool and I have selected the option to show share counts.我使用了“共享按钮”工具,并选择了显示共享计数的选项。 However, I believe the count is shown only if there is a significant amount of share.但是,我相信只有在有大量份额时才会显示计数。

My question is: Is it possible to always have the share buttons display the share counts even if it is zero?我的问题是:是否可以始终让共享按钮显示共享计数,即使它为零?

Here's the code that I got from AddThis:这是我从 AddThis 得到的代码:

<script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=ra-xxxxxxxxxxxxxxxx" async="async"></script>
<div class="addthis_sharing_toolbox"></div>

Thanks谢谢

If you want custom share buttons, you can make something like this: (this code is that I've been used in various projects, and it works fine. It only includes facebook, twitter and g+ but you can add all resources dispossed in addThis)如果你想要自定义分享按钮,你可以做这样的:(这段代码是我在各种项目中使用过的,效果很好。它只包括facebook、twitter和g+,但你可以添加addThis中处理的所有资源)

<div class="addthis_toolbox addthis_default_style ">
    <table width="100%" border="0">
        <tr>
            <td width="40%"><a class="addthis_button_facebook_like" fb:like:layout="button_count"></a></td>
            <td width="30%"><a class="addthis_button_tweet"></a></td>
            <td width="30%"><a class="addthis_button_google_plusone" g:plusone:annotation="bubble" g:plusone:size="medium"></a></td>
        </tr>
    </table>
    <script>window.___gcfg = {lang: "es"};</script>
</div>
<script type="text/javascript">var addthis_config = {"data_track_addressbar":true};</script>
<script type="text/javascript" src="http://s7.addthis.com/js/300/addthis_widget.js#pubid=ra-xxxxxxxxxxxxxxxxx"></script>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM