WordPress.org

Support

Support » Plugins and Hacks » Twitter Widget Pro » [Resolved] [Plugin: Twitter Widget Pro] Hide counter

[Resolved] [Plugin: Twitter Widget Pro] Hide counter

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Aaron D. Campbell

    @aaroncampbell

    That count is actually in an iframe showing from Twitter’s site, so you don’t have much control over it using CSS. However, there *is* a way to hide it. Add this code to the end of your theme’s functions.php file:

    function range_hide_follower_count( $attributes ) {
    	if ( ! empty( $attributes['class'] ) && 'twitter-follow-button' == $attributes['class'] )
    		$attributes['data-show-count'] = 'false';
    
    	return $attributes;
    }
    add_filter( 'widget_twitter_link_attributes', 'range_hide_follower_count' );

    That will add a new data element to the follow link, which tells Twitter you don’t want to show your follow count.

    Worked like a charm. Thanks so much, Aaron!

    Thanks so much! mr. aoron

    How about changing the locale language of this follow button?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Resolved] [Plugin: Twitter Widget Pro] Hide counter’ is closed to new replies.
Skip to toolbar