Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
I have set up Twitter, facebook and Google+ counter buttons as shown on the first attachment and on that widgets/sets/edit page they all show up OK. However if I go to a node that is configured to show them then I only see Facebook and Google+ as shown on the second attachment.
It seems that actually the code is not being generated - here's what output in links:
<div class="links">
<ul class="links inline">
<li class="socialmedia_share-default first"><span>
<div id="widgets-element-socialmedia_share-default" class="widgets widgets-set widgets-set-horizontal widgets-style-horizontal">
<div id="widgets-element-socialmedia_addthis-facebook-like" class="widgets widgets-element widgets-element-horizontal widgets-style-horizontal"><a class="addthis_button_facebook_like at300b" fb:like:layout="button_count" title="Facebook_like" href="#"><iframe style="overflow: hidden; border: 0px none; width: 90px; height: 25px; " src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fidris.test.ac.uk%2Fd7test5%2Fnode%2F100&layout=button_count&show_faces=false&width=100&action=like&font=arial&layout=button_count"></iframe></a>
</div>
<div id="widgets-element-socialmedia_addthis-google-plusone" class="widgets widgets-element widgets-element-horizontal widgets-style-horizontal"><a class="addthis_button_google_plusone at300b" g:plusone:size="standard" title="Google_plusone" href="#"><div style="height: 24px; width: 106px; display: inline-block; text-indent: 0px; margin: 0px; padding: 0px; background-color: transparent; border-style: none; float: none; line-height: normal; font-size: 1px; vertical-align: baseline; background-position: initial initial; background-repeat: initial initial; " id="___plusone_0"><iframe allowtransparency="true" frameborder="0" hspace="0" marginheight="0" marginwidth="0" scrolling="no" style="position: static; top: 0px; width: 106px; margin: 0px; border-style: none; left: 0px; visibility: visible; height: 24px; " tabindex="0" vspace="0" width="100%" id="I0_1348571429930" name="I0_1348571429930" src="https://plusone.google.com/_/+1/fastbutton?size=standard&callback=_at_plusonecallback&hl=en-US&origin=http%3A%2F%2Fidris.test.ac.uk&url=http%3A%2F%2Fidris.test.ac.uk%2Fd7test5%2Fnode%2F100&ic=1&jsh=m%3B%2F_%2Fapps-static%2F_%2Fjs%2Fgapi%2F__features__%2Frt%3Dj%2Fver%3DSjyRYw7b8zM.en_GB.%2Fsv%3D1%2Fam%3D!9Ag6gGPKM9qYppXIMg%2Fd%3D1%2Frs%3DAItRSTNw9TlZfRK2wsjtzAeBbaKvgZ8AJg#_methods=onPlusOne%2C_ready%2C_close%2C_open%2C_resizeMe%2C_renderstart%2Concircled&id=I0_1348571429930&parent=http%3A%2F%2Fidris.test.ac.uk" title="+1"></iframe></div></a></div><div class="widgets-clear">
</div>
</div>
<script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#username="></script></span>
</li>
<li class="social_media last"><span>
<div class="fb-like" data-send="false" data-layout="button_count" data-width="450" data-show-faces="false">
</div></span>
</li>
</ul>
</div>
Is there something obvious i'm doing wrong?
Comment | File | Size | Author |
---|---|---|---|
Screen Shot 2012-09-25 at 12.15.51.png | 19.46 KB | jinky32 | |
Screen Shot 2012-09-25 at 12.15.21.png | 60.86 KB | jinky32 |
Comments
Comment #1
jinky32 CreditAttribution: jinky32 commentedSorry to bump this but does anyone have any ideas?
Comment #2
Brizzle CreditAttribution: Brizzle commentedExperiencing the same issue with Twitter. Any ideas?
Comment #3
segi CreditAttribution: segi commentedI have same issue, twitter icon not appears.
Comment #4
tjerkdekuijper CreditAttribution: tjerkdekuijper commentedExactly the same issue for me.
version: 7.x-1.0-beta13
drupal: 7.15
Comment #5
Arganox CreditAttribution: Arganox commentedAll,
Is there any news on this issue?
I'm having the same problem as described above.
Comment #6
hvalentim CreditAttribution: hvalentim commentedSame here. Is it perhaps related with a conflict having the Twitter module installed?
Comment #7
Marcus Aurelius CreditAttribution: Marcus Aurelius commentedSame here!
Comment #8
zcrow CreditAttribution: zcrow commentedUsing the old, commented out code at line 279 in socialmedia.widgets.inc instead of the code at line 280 fixed it for me.
Comment #9
KarinW CreditAttribution: KarinW commentedI am having both the facebook button and the tweet share button not showing. Also the widgets for facebook and twitter with the countbox do not work. Is there any solution yet? (@zcrow which old code do yu mean? I installed for the first time).
Comment #10
renderfreak CreditAttribution: renderfreak commentedSame issue, but only when i'm logged in as a user (thankfully)...
Comment #11
reptilex CreditAttribution: reptilex commentedI downloaded the latest stable yesterday and had this issue too, but on top facebook was not showing up either so I exchanged it with the old stuff and it worked, something is broken in the latest stable.
To show the icons you have to go into the code
at line 128 you have to exchange the platforms[facebook][templates] variable with:
and at line 211 I uncommented the comment and comented the new line below:
Now the icons show, but I haven't yet tested whether all the share links work.
Comment #12
broonFor a project I experienced a similar error. The project has both a Twitter and a LinkedIn account but no Facebook page. The profile buttons showed up correctly (Twitter & LinkedIn), however the client requested that nodes may also be shared with Facebook. But the facebook button never showed up.
After entering my own facebook profile in the settings it suddenly worked and facebook share button showed up. So I assume there's some unnecessary connection or dependency between existing profiles and the share functionality.
Comment #13
etibmw CreditAttribution: etibmw commentedThank you Paul.B, You are right.
Only by adding the profiles for facebook and tweeter they will show up in the share.
Strange but true..
Comment #14
mikel1 CreditAttribution: mikel1 commentedSame problem. Adding profiles for Twitter makes button appear but it now shares on the profile account instead of the user's account, so still broken.
Comment #15
ailgm CreditAttribution: ailgm commentedThe organization my site is for has a Facebook page, but no Twitter account. Users will not be able to sign in, so I want to:
When I initially had Twitter selected as one of the site platforms, I had the same problem of the Twitter icon not appearing on the share widget (except on the widget admin page). After I removed it as a site platform, the icon still doesn't show up in the share widget AND this error is shown (twice) on admin pages:
Notice: Undefined index: username in socialmedia_twitter_tokens() (line 612 of .../sites/all/modules/socialmedia/socialmedia.platforms.inc).
(I'm using the dev version of the module)
Help would be appreciated.
Comment #16
Clonefall CreditAttribution: Clonefall commentedI'm having this same issue, missing Twitter button and I get this error:
Notice: Undefined index: username in socialmedia_twitter_tokens() (line 612 of /homepages/11/d502611008/htdocs/drupal7/sites/all/modules/socialmedia/socialmedia.platforms.inc).
Notice: Undefined index: username in socialmedia_twitter_tokens() (line 612 of /homepages/11/d502611008/htdocs/drupal7/sites/all/modules/socialmedia/socialmedia.platforms.inc).
Comment #17
joegl CreditAttribution: joegl commentedI had to get the Twitter share button working without a Twitter profile setup. Apparently the icon does not show for logged in users unless a Twitter profile is set (in the profile settings for the module). Same goes for Facebook/Pinterest (maybe others).
I can confirm that going into the socialmedia.widgets.inc file, finding the $platforms array for your widget, and then swapping to lines of commented code works. For me it was uncommenting line 279 and commenting out 280 instead.
Cheers!
Code included below (couldn't use the PHP tags because of formatting issues with the code):
Before
After