Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: PokémonS on January 02, 2013, 01:42:20 PM

Title: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on January 02, 2013, 01:42:20 PM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=3559)

Add Facebook Like, Tweet, and Google +1

Description
This mod adds Facebook Like, Twitter Tweet, and Google +1 to the first post which placed at the bottom.

How it works
Install this mod. Go to Administration Center » Configurations -> Modification Settings -> Miscellaneous to setting this mod. Please tick Enable socialization button (Facebook, Twitter, and Google+) first!

Feature Set
You can tick:
- Enable socialization button (Facebook, Twitter, and Google+)
- Show Facebook Like icon in the first post
- Show Twitter Tweet icon in the first post
- Show Google +1 icon in the first post

Screenshots
http://custom.simplemachines.org/mods/index.php?action=download;mod=3559;id=214777;image
http://custom.simplemachines.org/mods/index.php?action=download;mod=3559;id=214779;image

Versions

January 5, 2013 - v1.0.3a
- Fixed Tweet button (data-via & data-lang has been removed)

January 3, 2013 - v1.0.3
- Now the buttons are centered.

January 3, 2013 - v1.0.2a
- Fixed minor changes.

January 2, 2013 - v1.0.2
- First release.

Note
My first mod ._.

License
(http://i.creativecommons.org/l/by-nc-sa/3.0/88x31.png) (http://creativecommons.org/licenses/by-nc-sa/3.0/)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: 4Kstore on January 02, 2013, 08:22:07 PM
Congratulation for your first mod, looks great!
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on January 03, 2013, 12:48:17 AM
Congratulation for your first mod, looks great!
Thank you :)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: winsoft on January 03, 2013, 05:07:31 AM
that looks great, what i was looking for.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on January 03, 2013, 05:09:58 AM
Congrats and nice job. I hope to see more mods in the que from you :).
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: winsoft on January 03, 2013, 05:12:26 AM
Can we show the buttons on top the content instead?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on January 03, 2013, 06:06:50 AM
Congrats and nice job. I hope to see more mods in the que from you :).

Thanks Colin :)

Can we show the buttons on top the content instead?

Cut this code from Display.template.php

Code: [Select]
// Add Facebook Like, Tweet, and Google +1
if (!empty($modSettings['socialization_onoff'])) {
if ($message['id'] == $context['topic_first_message']) {
echo '
<div style="margin-left:auto;margin-right:auto">';

// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

// Show Twitter Tweet icon in the first post
if (!empty($modSettings['twitter_tweet'])) {
echo '
<a href="https://twitter.com/share" class="twitter-share-button" data-url="', $scripturl, '?topic=', $context['current_topic'], '" data-counturl="', $scripturl, '?topic=', $context['current_topic'], '" data-via="PokeStarsIndo" data-lang="en"></a><script type="text/javascript">!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>';
}

// Show Google +1 icon in the first post
if (!empty($modSettings['googleplus_plusone'])) {
echo '
<div class="g-plusone" data-size="medium"></div><script type="text/javascript">(function() {var po = document.createElement("script"); po.type = "text/javascript"; po.async = true;po.src = "https://apis.google.com/js/plusone.js";var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(po, s);})();</script>';
}

echo '
</div>
<br />';
}
}

And move it to after this code in Display.template.php:

Code: [Select]
<div class="post">';
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Gryzor on January 04, 2013, 07:44:40 AM
Cut this code from Display.template.php

Code: [Select]
// Add Facebook Like, Tweet, and Google +1
if (!empty($modSettings['socialization_onoff'])) {
if ($message['id'] == $context['topic_first_message']) {
echo '
<div style="margin-left:auto;margin-right:auto">';

// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

// Show Twitter Tweet icon in the first post
if (!empty($modSettings['twitter_tweet'])) {
echo '
<a href="https://twitter.com/share" class="twitter-share-button" data-url="', $scripturl, '?topic=', $context['current_topic'], '" data-counturl="', $scripturl, '?topic=', $context['current_topic'], '" data-via="PokeStarsIndo" data-lang="en"></a><script type="text/javascript">!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>';
}

// Show Google +1 icon in the first post
if (!empty($modSettings['googleplus_plusone'])) {
echo '
<div class="g-plusone" data-size="medium"></div><script type="text/javascript">(function() {var po = document.createElement("script"); po.type = "text/javascript"; po.async = true;po.src = "https://apis.google.com/js/plusone.js";var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(po, s);})();</script>';
}

echo '
</div>
<br />';
}
}

And move it to after this code in Display.template.php:

Code: [Select]
<div class="post">';

This is interesting, can you tell where exactly this modification places the buttons? In my view, the buttons should be separate from the post content. The best position for them would be in the post's title bar...

Thanks, looking good!
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on January 04, 2013, 08:23:24 AM
This is interesting, can you tell where exactly this modification places the buttons? In my view, the buttons should be separate from the post content. The best position for them would be in the post's title bar...

Thanks, looking good!

But, one thing. If you put those buttons before content, the buttons load it early than the content, and makes your forum laggy. D:

And, What would be happen if the buttons put in the post`s title bar, but the tittle is long?

(http://puu.sh/1Jo7J)

Maybe this place is better?

(http://puu.sh/1Jo77)

The code is:

In Display.template.php, find:

Code: [Select]
// Now show how many guests are here too.
echo $txt['who_and'], $context['view_num_guests'], ' ', $context['view_num_guests'] == 1 ? $txt['guest'] : $txt['guests'], $txt['who_viewing_topic'], '
</p>';
}

Add this after that:

Code: [Select]
// Add Facebook Like, Tweet, and Google +1
if (!empty($modSettings['socialization_onoff'])) {
echo '
<div style="margin-left:auto;margin-right:auto;text-align:left;padding-left:5px">';

// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

// Show Twitter Tweet icon in the first post
if (!empty($modSettings['twitter_tweet'])) {
echo '
<a href="https://twitter.com/share" class="twitter-share-button" data-url="', $scripturl, '?topic=', $context['current_topic'], '" data-counturl="', $scripturl, '?topic=', $context['current_topic'], '" data-lang="en"></a><script type="text/javascript">!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>';
}

// Show Google +1 icon in the first post
if (!empty($modSettings['googleplus_plusone'])) {
echo '
<div class="g-plusone" data-size="medium"></div><script type="text/javascript">(function() {var po = document.createElement("script"); po.type = "text/javascript"; po.async = true;po.src = "https://apis.google.com/js/plusone.js";var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(po, s);})();</script>';
}

echo '
</div>';
}
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Gryzor on January 04, 2013, 11:45:02 AM
Hmmm it is better indeed; my objection (if you can call it that) though is that the buttons shouldn't appear like they're part of the post, that's why I proposed the title bar. I do have a similar mod installed (no G+ though), and it doesn't seem like it slows page loading, to tell you the truth. If you want you can visit my site (under my avatar) to check it out.

Not sure about the title length, haven't encountered it yet :D But I think SMF has a limit that, used with most common resolutions, wouldn't matter for the buttons...?

Anyhow, thanks for your mod, it's something sorely missing :)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on January 05, 2013, 11:56:16 AM
Updated to v1.0.3a
- Fixed Tweet button (data-via & data-lang has been removed)

If you want to update this mod, please uninstall the previous version, and then install the latest version.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: dmask on January 07, 2013, 07:24:28 AM
hi, nice you fixed the "via" ;)

like i said here: http://www.simplemachines.org/community/index.php?topic=494109.msg3465057#msg3465057
with a little modification i was able to insert the adsense banner below the first post of a topic following how this mod works.

just find this
Code: [Select]
// Show Google +1 icon in the first post
if (!empty($modSettings['googleplus_plusone'])) {
echo '
<div class="g-plusone" data-size="medium"></div><script type="text/javascript">(function() {var po = document.createElement("script"); po.type = "text/javascript"; po.async = true;po.src = "https://apis.google.com/js/plusone.js";var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(po, s);})();</script>';
}

echo '
</div>
<br />
insert below
Code: [Select]
<div style="text-align:center; margin:5px;" >
<div style="margin:auto">
<script type="text/javascript"><!--
google_ad_client = "<<<<< YOUR ADSENSE ID HERE >>>>>";
/* Da post */
google_ad_slot = "<<<< unique slot number >>>>";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</div>
</div>';
attention for the GOOGLE_AD_CLIENT ad GOOGLE_AD_SLOT, look the code please.

in this way you will have:
facebook like - twitter - google+
<adsense banner> (468x60 in my case)

its a good mod, nice work PokémonS ;)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: impreza on January 10, 2013, 04:59:16 PM
Very good addition, at the end of something good
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: khanahmedabbas on January 11, 2013, 04:50:51 PM
i downloaded this mod but where to upload the files ? into which directory ?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: NanoSector on January 11, 2013, 07:20:43 PM
i downloaded this mod but where to upload the files ? into which directory ?
Please read this page: http://wiki.simplemachines.org/smf/Package_manager
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: NightzKung on January 11, 2013, 11:33:06 PM
Thankkkk for Mod!  ;D 
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ubaidchaudhary on January 28, 2013, 10:27:37 AM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=3559)

Add Facebook Like, Tweet, and Google +1

Description
This mod adds Facebook Like, Twitter Tweet, and Google +1 to the first post which placed at the bottom.

How it works
Install this mod. Go to Administration Center » Configurations -> Modification Settings -> Miscellaneous to setting this mod. Please tick Enable socialization button (Facebook, Twitter, and Google+) first!

You can tick:
- Enable socialization button (Facebook, Twitter, and Google+)

Where we can upload a mod file..??
And you said ''enable socialization buttons''
Where from we can enable socialization buttons ...???/
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: NanoSector on January 29, 2013, 03:59:34 AM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=3559)

Add Facebook Like, Tweet, and Google +1

Description
This mod adds Facebook Like, Twitter Tweet, and Google +1 to the first post which placed at the bottom.

How it works
Install this mod. Go to Administration Center » Configurations -> Modification Settings -> Miscellaneous to setting this mod. Please tick Enable socialization button (Facebook, Twitter, and Google+) first!

You can tick:
- Enable socialization button (Facebook, Twitter, and Google+)

Where we can upload a mod file..??
And you said ''enable socialization buttons''
Where from we can enable socialization buttons ...???/
http://wiki.simplemachines.org/smf/Package_manager
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MrTuborgDK on February 02, 2013, 04:03:46 PM
Hey, first of all i love this mod.....but i want so ask about something.....when i "like" a post and i see it at my Facebook activity...it are just showing a random photo there have npthing with post to do....

And sry for bad English..it are not my first speaking....;-)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on February 03, 2013, 04:41:59 AM
Hey, first of all i love this mod.....but i want so ask about something.....when i "like" a post and i see it at my Facebook activity...it are just showing a random photo there have npthing with post to do....

And sry for bad English..it are not my first speaking....;-)

First, Welcome to SMF Forum! Thanks for download my mod :)

If you don't want your thumbnail FB gets random, put this code to the <head> in index.template.php file:
Code: [Select]
<link rel="image_src" href="http://YOURTHUMBNAILFBHERE.png" />
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on February 03, 2013, 04:48:48 AM
Have someone try this mod in 2.0.4? Does it works?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ApplianceJunk on February 04, 2013, 12:14:58 PM
Works fine on 2.0.4, thanks!
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on February 06, 2013, 05:44:05 AM
Works fine on 2.0.4, thanks!
Thanks~ I've updated the mod's compatible version with 2.0.4.

Also, thanks to all for using this mod! Finally this mod is the most top 5 popular in SMF :D

(http://puu.sh/1YhvJ)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: DAVID. D.A on February 07, 2013, 06:36:19 AM
some errors:
Likes dont show on facebook wall

How do i change the 'via @PokeStarsIndo" in tweets to my site's handle and how do i change the recommended follow @PokeStarsIndo after tweets to my own account/handle?!

When someone tries to recommend on google+ the icon changes to a blurred out error triangle. how to fix please?

Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MarkS on February 07, 2013, 05:02:42 PM
some errors:
Likes dont show on facebook wall

How do i change the 'via @PokeStarsIndo" in tweets to my site's handle and how do i change the recommended follow @PokeStarsIndo after tweets to my own account/handle?!

When someone tries to recommend on google+ the icon changes to a blurred out error triangle. how to fix please?



same for me likes dont show on fb wall
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ApplianceJunk on February 07, 2013, 05:05:54 PM
Also, thanks to all for using this mod! Finally this mod is the most top 5 popular in SMF :D
(http://puu.sh/1YhvJ)

Awesome, congrats!
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MarkS on February 07, 2013, 05:20:01 PM
well ive checked the display template and from a no expert it look like the Manual Install Instructions parse looks
so sorry thats me lost :(
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheRealityBuzz on February 07, 2013, 07:47:03 PM
I downloaded this on my fourm, and it downloaded fine with no issues but it messed everything up with my links and what not and  this message appeared at the top of my screen

$txt['socialization_onoff'] = 'Enable socialization button (Facebook, Twitter, and Google+)'; $txt['facebook_like'] = 'Show Facebook Like icon in the first post'; $txt['twitter_tweet'] = 'Show Twitter Tweet icon in the first post'; $txt['googleplus_plusone'] = 'Show Google +1 icon in the first post';
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheRealityBuzz on February 07, 2013, 07:59:18 PM
On a side note, I tried to uninstall and it is not showing up , which is leaving everything completely thrown out of wack.  I've tried restoring to make it go away, but its not working.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: DAVID. D.A on February 08, 2013, 03:34:42 AM
To fix likes not showing on wall

Code: (find) [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

Code: (replace with) [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'],   '&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

To replace 'via @PokeStarsIndo' found in tweets

Code: (find) [Select]
PokeStarsIndo
Code: (replace with) [Select]
*Your own twitter handle*
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: DAVID. D.A on February 08, 2013, 03:37:46 AM
Is there a way to change the thumbnail of likes to my site's logo or favicon ?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MarkS on February 08, 2013, 03:41:07 AM
Thanks for this I will give it ago when I'm home from work
My twitter works ok straiange
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: DAVID. D.A on February 08, 2013, 03:52:22 AM
Just realized that it wasn't the mod that installed the via @PokeStarsIndo. I needed to move the buttons below the post title (as seen on the previous page) so i copied pokemons code while following his tutorial :laugh:

Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheRealityBuzz on February 08, 2013, 06:07:49 AM
Its not showing up anywhere so I can delete it, but it is messing everything up. Its not even showing up on my cpanel.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Sudhakar Arjunan on February 08, 2013, 06:31:31 PM
congrates for your first mod.

Trying now.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MarkS on February 08, 2013, 06:56:07 PM
To fix likes not showing on wall

Code: (find) [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

Code: (replace with) [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'],   '&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

To replace 'via @PokeStarsIndo' found in tweets

Code: (find) [Select]
PokeStarsIndo
Code: (replace with) [Select]
*Your own twitter handle*


thanks but both code do the same think they post in my recent activity as a like
and not on my wall other sites i have seen this on when you click like you can write something then it post on you wall
please some one tell me what im missing
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on February 12, 2013, 06:28:20 AM
Likes dont show on facebook wall
To fix likes not showing on wall

Code: (find) [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

Code: (replace with) [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'],   '&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

Thanks for the fix, but it looks like &amp;send=true/false is to display/undisplay the "Send" button.





How do i change the 'via @PokeStarsIndo" in tweets to my site's handle and how do i change the recommended follow @PokeStarsIndo after tweets to my own account/handle?!

But I have remove the data-via (@PokeStarsIndo) since a month ago ._. Please download the newest version.

Just realized that it wasn't the mod that installed the via @PokeStarsIndo. I needed to move the buttons below the post title (as seen on the previous page) so i copied pokemons code while following his tutorial :laugh:

Ah :okay:





When someone tries to recommend on google+ the icon changes to a blurred out error triangle. how to fix please?

Looks like Google error on that time? Is it working now?





Is there a way to change the thumbnail of likes to my site's logo or favicon ?

Look at this link: http://www.simplemachines.org/community/index.php?topic=494062.msg3482814#msg3482814




I downloaded this on my fourm, and it downloaded fine with no issues but it messed everything up with my links and what not and  this message appeared at the top of my screen

$txt['socialization_onoff'] = 'Enable socialization button (Facebook, Twitter, and Google+)'; $txt['facebook_like'] = 'Show Facebook Like icon in the first post'; $txt['twitter_tweet'] = 'Show Twitter Tweet icon in the first post'; $txt['googleplus_plusone'] = 'Show Google +1 icon in the first post';
On a side note, I tried to uninstall and it is not showing up , which is leaving everything completely thrown out of wack.  I've tried restoring to make it go away, but its not working.
Its not showing up anywhere so I can delete it, but it is messing everything up. Its not even showing up on my cpanel.

Wait, I don't know what you mean, what is the relation between cpanel and this mod?
Except you install it manually.
Also please make backup before you install any mod.




same for me likes dont show on fb wall
well ive checked the display template and from a no expert it look like the Manual Install Instructions parse looks
so sorry thats me lost :(
Thanks for this I will give it ago when I'm home from work
My twitter works ok straiange
... At least it works properly, and using DAVID. D.A's code.





thanks but both code do the same think they post in my recent activity as a like
and not on my wall other sites i have seen this on when you click like you can write something then it post on you wall
please some one tell me what im missing

The DAVID. D.A's code is to post your recent activity as a like, not to not post.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: NightzKung on February 16, 2013, 04:42:21 AM
add Facebook Like+share

Code: [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<div id="fb-root"></div>
<div style="margin-left:auto;margin-right:2em;text-align:center;padding-right:12px" class="fb-like" data-href="', $scripturl, '?topic=', $context['current_topic'], '" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-font="verdana"></div>';

../../index.template.php
find
Code: [Select]
// Here comes the JavaScript bits!
echo '

add after
Code: [Select]
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js#xfbml=1"></script>
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MarkS on February 16, 2013, 04:52:09 AM
Don't worry I've found a mod that does post on your wall

Shame
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: DAVID. D.A on February 16, 2013, 02:21:11 PM
How can this be added beside the reply buttons on top of post title please ?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: lailamax on February 17, 2013, 07:24:08 AM
thanks so much   :-*
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sangham.net on February 18, 2013, 11:11:38 AM
Sadhu! More than (http://sangham.net/Smileys/thumb_sangham.gif) Thank you very much!! (http://sangham.net/Smileys/sadhu_sangham.gif) (http://sangham.net/Smileys/sadhu_sangham.gif) (http://sangham.net/Smileys/sadhu_sangham.gif)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ausbream.info on March 02, 2013, 07:34:20 PM
I have installed this mod for 2.0.4 with no errors, when i click the like nothing is showing up on my facebook wall how can i go about fixing this error please
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: DAVID. D.A on March 03, 2013, 05:28:12 AM
I have installed this mod for 2.0.4 with no errors, when i click the like nothing is showing up on my facebook wall how can i go about fixing this error please
There's a fix on page 2

@op how can i close the wide gap between each button (flike, tweet, google+); so immediately after the number of likes or tweets, you find the next button, the gap is just too much.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ausbream.info on March 04, 2013, 05:32:29 PM
yeh i see now i thought this mod posted to my facebook wall
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: snadge on March 15, 2013, 06:01:34 PM
Hi,

Thanks for the mod.

when using the Twitter button it does not keep a number in the box like Facebook and Google+1, I have used all 3 and only Facebook and Google+1 have "1" in the box, i tried again but it refused saying I already posted it on twitter?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: koupe377 on March 15, 2013, 09:25:11 PM
I just installed this mod. It installed successfully and I ticked all 4 boxes but its not working. I started a  a couple new threads but there's no buttons. Is there another step that I need to do.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on March 17, 2013, 12:15:29 AM
What theme are you using?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: koupe377 on March 19, 2013, 02:52:25 PM
I'm using BlackRain. I also have tiny portal installed. thanks
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: koupe377 on March 19, 2013, 04:18:36 PM
fixed it. I uninstalled it and then re-installed it and made sure I had the blackrain them box checked.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: SC RaceFan on March 23, 2013, 09:40:02 PM
Nice Mod! I installed it on 2.0.4 and it looks right on my forum, when I click the FB like the # increases correctly. However, when I look at my FB wall I see a like but it only says "LogIn"  so it looks like I like a post Log In. LOL,,,, I was logged into my forum and FB at the same time. I'm not sure if the other changes\updates you offer here would apply to this or not.

Note: I had another member testing with me and they had the same results as mine on their FB as well.

So if you could, please help and thanks in advance for any ideas.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on March 24, 2013, 02:52:58 AM
it only says "LogIn"  so it looks like I like a post Log In.

I couldn't decipher this part. Would you mind rephrasing?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: formulax on March 26, 2013, 10:02:27 AM
Error

$txt['socialization_onoff'] = 'Enable socialization button (Facebook, Twitter, and Google+)'; $txt['facebook_like'] = 'Show Facebook Like icon in the first post'; $txt['twitter_tweet'] = 'Show Twitter Tweet icon in the first post'; $txt['googleplus_plusone'] = 'Show Google +1 icon in the first post';


(http://[url=http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb]http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb[/url])
Help me please !!!
<a href='http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb' title="ฝากไฟล์ - ฝากรูป  อัพโหลด ดาวโหลด  download upload  เร็วทันใจ" target=_blank>http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb</a>
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on April 01, 2013, 01:13:56 PM
How can this be added beside the reply buttons on top of post title please ?
Look at the page #1, http://www.simplemachines.org/community/index.php?topic=494062.msg3464425#msg3464425

Hi,

Thanks for the mod.

when using the Twitter button it does not keep a number in the box like Facebook and Google+1, I have used all 3 and only Facebook and Google+1 have "1" in the box, i tried again but it refused saying I already posted it on twitter?
Yeah me too, it's a common problem with Twitter.

Nice Mod! I installed it on 2.0.4 and it looks right on my forum, when I click the FB like the # increases correctly. However, when I look at my FB wall I see a like but it only says "LogIn"  so it looks like I like a post Log In. LOL,,,, I was logged into my forum and FB at the same time. I'm not sure if the other changes\updates you offer here would apply to this or not.

Note: I had another member testing with me and they had the same results as mine on their FB as well.

So if you could, please help and thanks in advance for any ideas.
It will be occur if guest can't view inside the forum. Facebook bot is a guest. The only solution you should change the "LogIn" title in Facebook to the title subject.

Error

$txt['socialization_onoff'] = 'Enable socialization button (Facebook, Twitter, and Google+)'; $txt['facebook_like'] = 'Show Facebook Like icon in the first post'; $txt['twitter_tweet'] = 'Show Twitter Tweet icon in the first post'; $txt['googleplus_plusone'] = 'Show Google +1 icon in the first post';


(http://[url=http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb]http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb[/url])
Help me please !!!
<a href='http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb' title="ฝากไฟล์ - ฝากรูป  อัพโหลด ดาวโหลด  download upload  เร็วทันใจ" target=_blank>http://www.boyr.com/getfile.php?id=1361760&key=5151a6f3a3cbb</a>
What's your problem? I even don't understand.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: dmilasin1 on April 05, 2013, 10:30:25 AM
I try couple of code provided here but still i can't get to post on wall only on activity  ???
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: dmilasin1 on April 05, 2013, 11:11:19 AM
Quote
If you don't want your thumbnail FB gets random, put this code to the <head> in index.template.php file:
Code: [Select]
<link rel="image_src" href="http://YOURTHUMBNAILFBHERE.png" />


i try that it works with g+ but not with facebook it take small icon from profile
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: PokémonS on April 06, 2013, 09:26:13 AM
I try couple of code provided here but still i can't get to post on wall only on activity  ???

Quote
If you don't want your thumbnail FB gets random, put this code to the <head> in index.template.php file:
Code: [Select]
<link rel="image_src" href="http://YOURTHUMBNAILFBHERE.png" />
i try that it works with g+ but not with facebook it take small icon from profile

Those because Facebook caching your forum.
So, icon cached by Facebook. Please try another topic (that haven't any FBlikes) to likes.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Dblog on April 08, 2013, 03:12:20 AM
can we show these 3 buttons on first post of each page in a topic.
few visitors may land on page 2,3,... and may want to like it
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: MiY4Gi on April 19, 2013, 07:29:07 PM
My facebook api button is wrong. Wasn't the mod supposed to install the box, and not the standard like button? At the moment my button is too wide. I only want the like box. Anyone else experiencing this?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: karde on April 23, 2013, 11:44:20 AM
can we change the button sizes and location of them?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ziycon on April 24, 2013, 07:02:02 PM
Nice mod, instead of changing the location, maybe add a dropdown select with a couple of different locations to place the social options but you can only have one location at a time.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mr-d on May 10, 2013, 01:29:32 PM
i wont work with mine smf site (2.04)
i cant find the line  / Mod authors, add any settings UNDER this line. Include a comma at the end of the line and don't remove this statement!! in /Sources/ManageSettings.php+

so i cant paste could you help please??
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on May 11, 2013, 02:06:20 AM
Will you upload your ManageSettings.php file, please?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mr-d on May 17, 2013, 01:58:49 PM
sorry for my late reaction but i fixed it

i dit an uninstall and re-install with the sipder board and topic acces plugin and then that line was visible again

thankxz for your reaction

greetzss D
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on May 17, 2013, 04:50:32 PM
Glad to hear it. Thanks for coming back and sharing your solution. Be sure to let us know if you run into any other trouble.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sanax on May 19, 2013, 03:32:47 PM
Great mod although I made all the coding changes on page 2 and the FaceBook window still doesn't come up to share on your wall. I have a new 2.0.4 and the latest mod installed

Any ideas?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sanax on May 23, 2013, 11:15:07 AM
Bump
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: GLMontyWV on June 07, 2013, 03:39:14 PM
Great mod, thanks!  Any easy way to add a hashtag to the tweet button?

THANKS!
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sandiplfcg on July 18, 2013, 04:50:51 PM
I'm using RedPRoV1 theme. I'm not able to use this plugin. Help
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheListener on July 18, 2013, 04:57:09 PM
I'm using RedPRoV1 theme. I'm not able to use this plugin. Help

Please assist us with more information.

Why are you not able to use this mod?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sandiplfcg on July 18, 2013, 05:10:45 PM
Tried to install the mod with SMF, it said it was successfully installed but when i tried to access its feature under miscellaneous there was no option in it. Later on i tried to do it manually, only the tick box option is showing nothing is written beside it( i did pasted the code in language file) and i'm not able to edit the templete file don't know where to put the code in. Newblie here sorry for the trouble.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheListener on July 18, 2013, 05:15:36 PM
Which language is the forum in?

Any errors on install?

Please check your forums error log also.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sandiplfcg on July 18, 2013, 05:26:58 PM
It's in English.
No error was found.
Don't see any error related to to this mod.
Can you help me , setting it up manually? Tried it, i really don't where to put the code in the index.template.php file (not using the default one)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheListener on July 18, 2013, 05:29:06 PM
What is the link to the forum?

So there were no test failed messages on install?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sandiplfcg on July 18, 2013, 05:33:13 PM
http://bengalkop.orgfree.com/forum/index.php
No there was no test fail r
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sandiplfcg on July 18, 2013, 09:23:05 PM
Guess, i was able to fix the problem. Editing Default temple file in the default folder  ( didn't knew it was connect to my theme)Is there a way to show the like and tweet botton  in every single post ?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: azirion on July 30, 2013, 01:12:54 PM
Hi

This mod sounds exactly what I need on my forum 8) But sadly it doesnt work on my site. I have Spanish ES language. Is this the reason it does not work? Is there a way I can make it work with this language?

Im using core theme and SPortal mod.

site: acuarioscr.com

Thanks in advance  ;)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TheListener on July 31, 2013, 06:32:27 PM
Quote
it doesnt work on my site

This doesn't tell us anything.

Why doesn't it work on your forum?

Any errors on install?

Does the mod work on the default theme?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: azirion on July 31, 2013, 11:09:51 PM
Quote
it doesnt work on my site

This doesn't tell us anything.

Why doesn't it work on your forum?

Any errors on install?

Does the mod work on the default theme?
Im sorry, my bad. I did it all again and this time it worked like a charm! Thanks a lot, its a very cool mod  ;)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: IgorS on August 04, 2013, 03:28:54 PM
Hi!

Thanks for really great mod!

Is this possible to put FB, Tweeter and Google+ buttons to every post in topic, not only to the first?

I'd like to add this buttons to every post in every topic - becouse I want to allow users to like each post (not whole topic but single post). What should I change?

Thanks in advance, Igor.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: tsis_k on August 09, 2013, 10:08:40 AM
Hello everyone,

I am having the same problem as many of you do. The facebook like only appear in my activity log, however, I noticed that I can manually publish each like from my activity log to my timeline. Having to manually publish each like from the activity log to the timeline really sucks and time consuming.

I want my facebook likes to appear automatically to my timeline. I'm sure this is a facebook privacy setting but I can't find how to enable facebook likes to post to the timeline automatically.  If anyone found a solution, please share.

I also would like to know if/how I change the facebook like icon to facebook recommend icon instead. It's more fitting to forum post, IMO.

Thanks.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: AllanD on September 25, 2013, 08:27:53 PM
It is possible to have this show on every post not just the top one?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HackAl on October 06, 2013, 08:08:44 PM
Hello.

I love this mod and hope I can get it to work.  I tried installing at www.hackensacknow.com.  I enabled everything in Modification Settings but I don't see the FB/Tweet/Google buttons in my topics. 

No error messages.  I'm wondering what I missed. 

Thanks in advance.
++++++++++++++++++++++=
Figured it out.  Sorry. Thanks.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: AllanD on October 06, 2013, 08:31:08 PM
It display on the first post at the bottom.   I checked and I see it displayed on your posts.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: ardvark on October 29, 2013, 10:20:10 AM
Anyone having any luck with this on 2.06?  I am having the same issue as others with the Facebook button not actually having any effect on Facebook. Pokémon, the mod works amazingly well on your personal site and I would love that functionality as well!  Thanks for the mod.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sparky33 on November 15, 2013, 10:15:59 AM
Mod works a treat, but is there any way to apply it to every post?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Arantor on November 15, 2013, 11:33:06 AM
Fairly sure that's not possible because those things all rely on the URL of the page in question, not a part of a page.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: amadeos on November 18, 2013, 09:02:23 AM
This mod is exactly what I've been looking for)
Thanks
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mrkid on December 08, 2013, 01:05:19 PM
I can't get the any of the buttons to show. Everything is checked in the settings. I thought it was my adblocker, but turned that off and still nothing. I'm running 2.06.
Another interesting part to this is when I tried to uninstall. It tries to remove the same code from two different files. Only one of which contains the code according to the parse list.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mrkid on December 09, 2013, 06:11:27 PM
I'm thouroughly confused now. I just checked two of the sites in this thread that people say the buttons are working fine, and I can't see them. Can someone please check if they can see them on my site? http://www.hauntersnation.com/forum/index.php?action=forum

I'm wondering if something is blocking them on my computer?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Arantor on December 09, 2013, 06:18:12 PM
Well, in your theme's code I see:
Code: [Select]
<center><script language="JavaScript" type="text/javascript">
top();
</script></center>

but top() is not declared and so the browser reports a JavaScript error - and this disables all other code after it.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mrkid on December 09, 2013, 07:17:12 PM
That's strange. I see that in the index.template.php, but when I try anything to change it, I get the white screen of death. It's actually the original code from the Black Rain V2 theme.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mrkid on December 12, 2013, 08:37:19 PM
So I straightened out that rogue script. It was leftover from another mod I removed. Still have no buttons showing. I've tried just about every mod to get e google + button in the first post (or any post) and they just never work. Any ideas? ???
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: mrkid on December 13, 2013, 11:23:38 AM
It's all fixed now. After noticing everything worked on my mobile page, I checked IE and Chrome. Both were showing the all of the buttons(though IE had them out of line)
I went and reset Firefox by going to Firefox>Help>Troubleshooting information then hit Reset Firefox. It saved all my info, and fixed some things that got botched in the latest upgrade. Hopefully this will help other people fix some "unsolvable" issues.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on December 28, 2013, 04:38:09 PM
Great MOD . I did the manual install for SMF 2.0.6 and looks fine with the default theme.
Now only with my own theme the buttons dont show.
I use a variation of the BlackrainV2 Theme (the same only different color).
further no errors.
Same issue in all browsers.
Any idea?

Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on December 29, 2013, 02:35:43 AM
Were there any errors reported on installation, with the custom theme checked?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on December 29, 2013, 03:09:08 AM
No errrors cause I did the manual installation (package manager currently doesnt work for me). further it just worked straight ahead.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on December 29, 2013, 04:22:42 AM
 :o
 It's working!  8)
I had just forgotten to add the corresponding code to Display.template.php of my own Theme (and all other then default).
My bad.
Must have been very tired yesterday  :laugh:

Thanks anyway Colin
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on December 29, 2013, 05:24:28 AM
add Facebook Like+share

Code: [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<div id="fb-root"></div>
<div style="margin-left:auto;margin-right:2em;text-align:center;padding-right:12px" class="fb-like" data-href="', $scripturl, '?topic=', $context['current_topic'], '" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-font="verdana"></div>';

../../index.template.php
find
Code: [Select]
// Here comes the JavaScript bits!
echo '

add after
Code: [Select]
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js#xfbml=1"></script>

Thanks a lot for this addition !
Right what I was lookin for. Now it has the share/like thingy from Fb, like the twitter and google button. This makes this mod almost perfect! . :D
I'd like to advise to Pokemons to add this one to next time.

Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Colin on December 29, 2013, 12:45:38 PM
:o
 It's working!  8)
I had just forgotten to add the corresponding code to Display.template.php of my own Theme (and all other then default).
My bad.
Must have been very tired yesterday  :laugh:

Thanks anyway Colin

Fantastic :)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: trollkin on January 12, 2014, 03:31:34 AM
add Facebook Like+share

Code: [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<div id="fb-root"></div>
<div style="margin-left:auto;margin-right:2em;text-align:center;padding-right:12px" class="fb-like" data-href="', $scripturl, '?topic=', $context['current_topic'], '" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-font="verdana"></div>';

../../index.template.php
find
Code: [Select]
// Here comes the JavaScript bits!
echo '

add after
Code: [Select]
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js#xfbml=1"></script>

Thanks a lot for this addition !
Right what I was lookin for. Now it has the share/like thingy from Fb, like the twitter and google button. This makes this mod almost perfect! . :D
I'd like to advise to Pokemons to add this one to next time.


I've installed the mod in my forum (2.06) and Twitter and Google+ buttons works fine. Fb button has no effect and I want to add the code above. I am newbie and I have no idea where and how to add the code.

Can anybody help me?

Thank you!
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on January 12, 2014, 06:57:40 AM
You have to paste into the code of the index.template.php file of the Themes you want it to show. The default theme to start with.
In fact your FB button does work, only does not show what you expect. With above edits it will show what you expect, the share screen where you can type a message and show on your wall.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: sorularbiz on January 12, 2014, 07:02:11 AM
Hi, this plugin is compatible with recent sur? Is there only one language? Can we just put pictures to share it?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on January 12, 2014, 08:49:46 AM
Dont know about package manager but I did the manual installation and it works.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on January 15, 2014, 08:16:16 AM
Is there only one language? Can we just put pictures to share it?

In case of FB language is in the url like:
Code: [Select]
https://connect.facebook.net/en_US/all.js#xfbml=1
If you change en_US into your preferred country/language code it will show the sharescreen/button in your language
In my case nl_NL which shows the FB share screen  in Dutch from the netherlands.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TeeJay on January 18, 2014, 07:01:34 AM
add Facebook Like+share

Code: [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<div id="fb-root"></div>
<div style="margin-left:auto;margin-right:2em;text-align:center;padding-right:12px" class="fb-like" data-href="', $scripturl, '?topic=', $context['current_topic'], '" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-font="verdana"></div>';

../../index.template.php
find
Code: [Select]
// Here comes the JavaScript bits!
echo '

add after
Code: [Select]
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js#xfbml=1"></script>

Thanks a lot for this addition !
Right what I was lookin for. Now it has the share/like thingy from Fb, like the twitter and google button. This makes this mod almost perfect! . :D
I'd like to advise to Pokemons to add this one to next time.


I've installed the mod in my forum (2.06) and Twitter and Google+ buttons works fine. Fb button has no effect and I want to add the code above. I am newbie and I have no idea where and how to add the code.

Can anybody help me?

Thank you!

Same problem for me no Facebook function and I have no idea what that code is or where to put it if indeed I need to ?

SMF 2.06
www.vdsr.co.uk
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: TeeJay on January 18, 2014, 07:35:50 AM
Never mind, I've removed the mod, as good as it is I can't be doing with modifying scripts, it all gets too messed up when it's time for upgrades etc, rather have something that can be installed and uninstalled without manual script mods

Thanks though
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Juan Carlos on January 25, 2014, 09:43:07 PM
Same for me.

nothing happens with fb. I already make the page 2 instructions
smf 2.0.7
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: WCFA on February 07, 2014, 04:40:37 PM


Newbie question here.

I have 2.0.7 on a new forum with a theme other then stock.
Id like to install this into my forum, but it appear because I am not using stock I will need to do so manually.
Is there a manual version to install via non default theme.

2nd newbie question, are there ever any mods that work with a non default theme? I find they all fail even if made
for 2.0.07

Thanks for the help.








Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on February 08, 2014, 03:34:57 AM
Is there a manual version to install via non default theme.

2nd newbie question, are there ever any mods that work with a non default theme? I find they all fail even if made
for 2.0.07

Thanks for the help.


Sure... use parse function at right side of the mod page, will give you:  http://custom.simplemachines.org/mods/index.php?action=parse;mod=3559;attach=214901;smf_version=2.0.7

works with all themes.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: forum12 on April 21, 2014, 12:57:10 AM
Awesome mod is there a way to make it show up on every post?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on May 14, 2014, 12:00:13 PM
hello, does it work on SMF 2.0.2 ?

For some reasons I cannot upgrade to newer version otherwise I lose some mods my webmaster made...thanks
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Arantor on May 14, 2014, 12:09:54 PM
So you'd rather be insecure than 'lose mods' despite the fact that you can install each version beyond 2.0.2 as a mod...
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on May 14, 2014, 12:23:40 PM
So you'd rather be insecure than 'lose mods' despite the fact that you can install each version beyond 2.0.2 as a mod...

well I backup once a week...the mods he did are not something I can find anywhere else: he edited the code so that no member can PM anybody else...I need that but no one here was able to do it.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Arantor on May 14, 2014, 12:33:21 PM
I still don't see why you can't just install the mod packages for 2.0.2 -> 2.0.3, 2.0.3 -> 2.0.4 etc. as per http://custom.simplemachines.org/upgrades/
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on May 15, 2014, 04:04:48 PM
I still don't see why you can't just install the mod packages for 2.0.2 -> 2.0.3, 2.0.3 -> 2.0.4 etc. as per http://custom.simplemachines.org/upgrades/

alright I got up to 2.05 then I got an error which I have to check, however I installed this mod too but I am getting double icons:

Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on May 15, 2014, 04:05:46 PM
also, did not notice this mod only was for first post of each topic, is there any other similar mod for each post/reply?

Thanks
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on May 25, 2014, 02:55:41 AM
 :'(
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Arantor on May 25, 2014, 11:16:53 AM
All of the different like schemes are really designed for entire pages, not really individual posts.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Kindred on May 25, 2014, 10:20:00 PM
1- you got double icons because you installed the mod twice.
Now you are going to have to manually go through the code and remove the duplicated portions.

2- it's the way things are.  Facebooks, google, etc do not "like" a single post. They "like" the page/url.   That's how they are designed.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on June 01, 2014, 04:52:08 AM
1- you got double icons because you installed the mod twice.
Now you are going to have to manually go through the code and remove the duplicated portions.

ouch...that sounds complicated :(

Is there any step by step guide for dummies?

Thank you
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: handy1 on June 11, 2014, 01:20:09 AM
add Facebook Like+share

Code: [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<div id="fb-root"></div>
<div style="margin-left:auto;margin-right:2em;text-align:center;padding-right:12px" class="fb-like" data-href="', $scripturl, '?topic=', $context['current_topic'], '" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-font="verdana"></div>';

../../index.template.php
find
Code: [Select]
// Here comes the JavaScript bits!
echo '

add after
Code: [Select]
<script type="text/javascript" src="https://connect.facebook.net/en_US/all.js#xfbml=1"></script>

Thanks a lot for this addition !
Right what I was lookin for. Now it has the share/like thingy from Fb, like the twitter and google button. This makes this mod almost perfect! . :D
I'd like to advise to Pokemons to add this one to next time.

Well, maybe someone could explain this to me too  8)

I should add

Code: [Select]
// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<div id="fb-root"></div>
<div style="margin-left:auto;margin-right:2em;text-align:center;padding-right:12px" class="fb-like" data-href="', $scripturl, '?topic=', $context['current_topic'], '" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-font="verdana"></div>';

somewhere in index.template.php in my theme folder? What is the right place, I tried it above

"// Here comes the JavaScript bits!
   echo '"


But it gave an error (hole site went down).
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: webpermoter2014 on June 11, 2014, 05:15:28 AM
that looks great, what i was looking for.

That's cool..
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Joomlamz on October 18, 2014, 12:21:41 PM
When update dont forget portuguese files

Code: [Select]
<file name="$languagedir/Modifications.english-utf8.php" error="skip">
        <operation>
            <search position="end" />
            <add><![CDATA[
$txt['socialization_onoff'] = 'Enable socialization button (Facebook, Twitter, and Google+)';
$txt['facebook_like'] = 'Show Facebook Like icon in the first post.';
$txt['twitter_tweet'] = 'Show Twitter Tweet icon in the first post.';
$txt['googleplus_plusone'] = 'Show Google +1 icon in the first post.';
]]></add>
        </operation>
    </file>

<file name="$languagedir/Modifications.portuguese_pt.php" error="skip">
        <operation>
            <search position="end" />
            <add><![CDATA[
$txt['socialization_onoff'] = 'Activar bot&atilde;o socializa&ccedil;&atilde;o (Facebook, Twitter, and Google+)';
$txt['facebook_like'] = 'Mostrar &iacute;cone do Facebook Como no primeiro poste.';
$txt['twitter_tweet'] = 'Mostrar Twitter Tweet &iacute;cone Como no primeiro poste.';
$txt['googleplus_plusone'] = 'Mostrar &iacute;cone do Google +1 no primeiro poste.';
]]></add>
        </operation>
    </file>
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Segnali on December 06, 2014, 04:36:15 AM
1- you got double icons because you installed the mod twice.
Now you are going to have to manually go through the code and remove the duplicated portions.

ouch...that sounds complicated :(

Is there any step by step guide for dummies?

Thank you


I am still with the double icons issue :(

Can anyone help me please?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Kindred on December 06, 2014, 09:03:59 AM
go to http://custom.simplemachines.org/mods/index.php?mod=3559
click parse
look through each change ordered by the mod
undo the duplicate changes
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: HRM on December 06, 2014, 11:20:36 AM

I am still with the double icons issue :(

Can anyone help me please?

Follow Kindreds link or check in
./Themes/default/Display.template.php   for 
Code: [Select]

// Add Facebook Like, Tweet, and Google +1
if (!empty($modSettings['socialization_onoff'])) {
if ($message['id'] == $context['topic_first_message']) {
echo '
<br />
<div style="margin-left:auto;margin-right:auto;text-align:center;padding-left:12px">';

// Show Facebook Like icon in the first post
if (!empty($modSettings['facebook_like'])) {
echo '
<iframe src="http://www.facebook.com/plugins/like.php?href=', $scripturl, '?topic=', $context['current_topic'], '&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;font&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:20px;" allowTransparency="true"></iframe>';
}

// Show Twitter Tweet icon in the first post
if (!empty($modSettings['twitter_tweet'])) {
echo '
<a href="https://twitter.com/share" class="twitter-share-button" data-url="', $scripturl, '?topic=', $context['current_topic'], '" data-counturl="', $scripturl, '?topic=', $context['current_topic'], '"></a><script type="text/javascript">!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>';
}

// Show Google +1 icon in the first post
if (!empty($modSettings['googleplus_plusone'])) {
echo '
<div class="g-plusone" data-size="medium"></div><script type="text/javascript">(function() {var po = document.createElement("script"); po.type = "text/javascript"; po.async = true;po.src = "https://apis.google.com/js/plusone.js";var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(po, s);})();</script>';
}

echo '
</div>
<br />';
}
}


being twice in there or in:
./Sources/ManageSettings.php
Code: [Select]
array('check', 'socialization_onoff'),
array('check', 'facebook_like'),
array('check', 'twitter_tweet'),
array('check', 'googleplus_plusone'),

being double.


Also some themes have their own Display.template.php so you have to check that as well if needed.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Bob La Londe on January 18, 2015, 02:32:41 PM
So where exactly do the Facebook likes show up?  I installed this on two forums I manage, and the only place I could find the likes was on my history.  Not on my Facebook page or on my Home feed. 
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: baywatcharms on January 20, 2015, 11:52:13 PM
Can you explain exactly what this mod is suppose to do.  I am a little bit confused.  I installed the mod, it seems to be working, but not sure if it is working correctly.  The icons show up on the first post.  When I click like on the FB button, it changes to ! like.  If I click on the twitter, it pops up a share screen for twitter, if I share the tweet, it shows up on my twitter account.  But the number does not change from 0 to 1.  Another thing is that the FB like prompts me to login as me.  It won't let me use the page that I manage, and nothing seems to post to my FB.  Have I done something wrong?  Can you help?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: baywatcharms on January 21, 2015, 12:34:21 PM
I have just read almost all the post regarding this mod.  I am kind of at a loss right now.  Wondering if I should uninstall, and and install again manually. 
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: 0Connors on February 06, 2015, 09:12:10 AM
Hi,

Thank you for this mod, but the mod don't share the post on my facebook wall too, and  Twitter counter not work :( Can you fix it, please  ?!

Thank you,
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: 0Connors on February 16, 2015, 09:03:11 AM
Hi,

Finaly, the twitter's counter works fine ! But i still have the problem with facebook.

Thank you for your help in advance,
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Kindred on February 16, 2015, 09:07:47 AM
Correct, it does not share the page on your facebook wall... It just does facebook like...
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: 0Connors on February 16, 2015, 09:12:38 AM
Hi Kindred,

Oh it's too bad, but thank you for your quickly answer,

Have good day,
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Miker1029 on March 18, 2015, 12:29:48 PM
I don't know what's up, If I'm doing something wrong or what,  But I don't have ANY Buttons and The FB Button Doesn't have a BOX to Check, No Buttons are showing in posts, Tried New Post to Test, Nothing is there, I've Installed Multiple Times and Even Did it Manually and still nothing, Not Even On the CORE theme....  Am I missing something here?? Permissions or Something??

SMF 2.0.9

Any Help Appreciated,

Mike

Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: SomaliDoc on May 05, 2015, 10:32:10 AM
I have noticed  when I am using Facebook debug, it is showing me these warning messages:

Admins And App ID Missing fb:admins and fb:app_id tags are missing. These tags are necessary for Facebook to render a News Feed story that generates a high clickthrough rate.
Like Button Tag Missing og:title is missing. The og:title meta tag is necessary for Facebook to render a News Feed story that generates a high clickthrough rate.

Where can I place those "og tags"?

I hope someone understands what I am talking about...

Thanks
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: blackbear4110 on June 26, 2015, 01:58:18 PM
I finally managed to get this package installed.  For some reason it didn't want to download from the url (wasn't extracting any files for some reason), so finally I downloaded the file to my pc and uploaded the package to the package manager that way.

Anyway, now that I have this mod installed, I checked all features to turn on.  But they are not showing up.  I can not see the FB icon, the Twitter icon, or the Google+ icon in any post.  It's as if I didn't install anything.
I'm using SMF 2.0.10 (and have also tried simulating to 2.0.9 in case that was a problem, but that didn't change anything).  And my default theme is Lucid Dreams. 

Not sure what other info you might need to help me figure out why this isn't working.

Thanks in advance~
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: SomaliDoc on June 26, 2015, 02:02:56 PM
Go to
Admin -> Configuration -> Modification settings -> Miscellaneous, then enable the icons from there.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Miker1029 on June 26, 2015, 02:05:21 PM
AND if that doesn't work, use SA, I've tried this one awhile ago and it didn't work,  Only Drawback is SA Facebook is (was) broke....

Mike
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: blackbear4110 on June 26, 2015, 03:04:52 PM
Go to
Admin -> Configuration -> Modification settings -> Miscellaneous, then enable the icons from there.
I did that, but it wasn't working.  So I uninstalled the mod, and reinstalled it.  Now the icons show up, but I just tested it by tweeting a topic, and the counter is still showing 0 instead of 1.

I guess I'll go try SA.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Douglas on July 30, 2015, 11:08:05 PM
Upgraded to 2.0.10 tonight (fresh files) and the admin config options are not showing.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: lordf on November 09, 2015, 02:23:01 AM
In Chrome the faceebook icon is missing, in others browsers it works perfectly. Any solution?
Thanks
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: neggard on December 16, 2015, 07:02:48 PM
I just installed this mod. No errors when install.

Activate all 4 boxes.

Dont see any button.
What could I do?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Harvester on February 20, 2017, 09:10:27 PM
do these buttons actually reflect on facebook when we like a post?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Harvester on March 17, 2017, 08:53:32 PM
Does anyone know the answer to this for me?

Im starting to think that the Like is not linked to Facebook in any way and that I am probably better of just removing this mod.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: cpf on September 26, 2017, 05:36:43 PM
I am trying to uninstall this mod, but I keep getting the following error:

Quote
2.   Execute Modification   ./Sources/ManageSettings.php   Test failed
   1.   Replace   ./Sources/ManageSettings.php   Test failed

Is it safe to continue with the uninstall?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Kindred on October 13, 2017, 07:14:27 PM
you will have to manually undo those code changes, the same way you would on an failed installation
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: whoey on February 28, 2018, 02:40:49 PM
In Chrome the faceebook icon is missing, in others browsers it works perfectly. Any solution?
Thanks
change the facebook url to use https in Display.template.php

Code: [Select]
<iframe src="http://www.facebook.com/plugins/like.php?href=',to
Code: [Select]
<iframe src="https://www.facebook.com/plugins/like.php?href=',
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: njtweb on April 25, 2018, 03:23:10 PM
Thank you, I think it's working as intended. If you click facebook like is it just liked there in the forum, it doesn't send open up a post to Facebook window like Twitter does if you click that?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: floyde on June 28, 2018, 04:41:34 PM
I see now, I thought this mod mod posted to facebook wall,

but it's not posted to facebook wall.
somebody help me?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Kindred on June 28, 2018, 08:35:17 PM
no. this mod does just what it says.  facebook LIKES...   AFAIK, there are not currently any mods which will post to your facebook wall.
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: floyde on June 28, 2018, 08:53:57 PM
no. this mod does just what it says.  facebook LIKES...   AFAIK, there are not currently any mods which will post to your facebook wall.

I can create the share button, do you have any idea how to put the post?

when I click share it does not look like the post automatically.

Do not share the post

Code: [Select]
<iframe src="https://www.facebook.com/plugins/share_button.php?href=https%3A%2F%2Fwww.my-site.com.br&layout=button_count&size=small&mobile_iframe=true&appId=5454541254545478&width=107&height=20" width="107" height="20" style="border:none;overflow:hidden" scrolling="no" frameborder="0" allowTransparency="true" allow="encrypted-media"></iframe>';
}

(https://i.imgur.com/c4ifYX6.png)
Do you have any idea how the topic will appear here?
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: Kindred on June 28, 2018, 11:54:54 PM
That is what I just said.. there are no mods which do this because it is much more complicated than you seem to think. Additionally Facebook keeps changing their API which makes it more difficult to maintain any application that is built. Finally iframes are bad practice overall
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: floyde on June 29, 2018, 12:06:56 AM
That is what I just said.. there are no mods which do this because it is much more complicated than you seem to think. I just only Facebook keeps changing their API which makes it more difficult to maintain any application that is built. Finally iframes are bad practice overall

I did a mod edition, and it worked very well,

if someone wants the mod edited just send me pm

(https://i.imgur.com/MHnCwyI.png)

(https://i.imgur.com/F5g4EWA.png)

(https://i.imgur.com/z1OuQDe.png)
Title: Re: Add Facebook Like, Tweet, and Google +1
Post by: njtweb on June 29, 2018, 03:19:40 PM
I see now, I thought this mod mod posted to facebook wall,

but it's not posted to facebook wall.
somebody help me?

This is your best option. Works great for me. Adds the "Share this bar" above or below your post text with every social platform option to share to contained. No mess of icons all over your topic.

Share This Topic Mod (https://custom.simplemachines.org/mods/index.php?mod=2111)