Needs review
Project:
Service links
Version:
7.x-2.3
Component:
User interface
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
15 Feb 2013 at 19:26 UTC
Updated:
21 Aug 2015 at 01:50 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
TheCrow commentedput the address of your website...
Comment #2
simon georges commentedComment #3
tvilms commentedHere it is. Thanks.
http://www.musiceum.com
Comment #3.0
tvilms commentedMinor edit to explain I'm not using a real URL
Comment #4
leeotzu commentedI am also facing same issue. Any resolution to this?
Comment #5
proteo commentedHi you all. I've had this issue with a brand new site that was just moved from development to production. After a few minutes I figured out the problem: the widget uses the shortened URL (I'm using the Bit.ly service) to format the counturl parameter in the link's URL, not the actual node URL (instead the Bit.ly URL I should see the canonical URL so, since I'm using Pathauto, I should see node's clean URL).
Since I was in a hurry and all i needed was a quick and dirty fix, I just added this line to the
ws_twitter_widget_data()function, in the line # 95:That overrides the shortened URL for the counturl param. I tried doing the same thing changing &counturl=encoded-url to &counturl=encoded-long-url in the
$links['twitter_widget']array fromwidget_services_service_links(), but for some reason that didn't work, and as I said, didn't have time to go through the code.I hope the mantainer can gather from this the necessary info to make a proper fix, but in the meantime you can use the little hack above.
Best regards.
Comment #6
jenpasch commentedStill an issue.
Comment #7
proteo commentedHi you all. As I posted in #5, I solved the problem by changing one line in the widget_services.module file. Today, I updated a couple of sites to 7.x-2.3, again losing the counter in the Twitter button. However, I wasn't able to apply the same "fix", the counter always remains at 0.
The solution happens to be in Twitter's documentation (no surprise). The source of the problem is that Twitter no longer honors the counturl parameter in the URL. Instead, this must be provided in the form of a new attribute called data-counturl: Tweet Button Parameter Reference.
I'm attaching a patch that fixes the problem. It's done against the 7.x-2.x branch in the repo.
Please test and post your results, best regards.
Comment #8
drupalove commentedThis last patch makes sense but still didn't work for me. The counter doesn't show up, even by adding
$params['count'] = 10;still it doesn't show up.Comment #9
orcode commentedAccording to Twitter, tweet counts were removed from the JSON response and the tweet button a couple of months ago:
https://twittercommunity.com/t/a-new-design-for-tweet-and-follow-buttons...