The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
![]() |
|||||||||||||||||||||||||||||||||||
Add New Facebook "Like" button to your threads
![]() Developer Last Online: Feb 2022 ![]() ![]()
Please remember to click Mark as Installed if you use this modification.
Facebook has just launched their latest "Like" button to developers to use on any site. What this does is utilizes the Advertising module to add the "Like" button to the first post of each thread. Please see screenshots to get an idea. In your Admin CP go to Advertising > New Ad > Choose "Thread" from the dropdown and then select the first thread box. Give it a title (I called mine FB Like) leave "First Post Content" at default and paste in this code: HTML Code:
<!-- Facebook Like --> <iframe src="http://www.facebook.com/plugins/like.php?href=http://www.YOURSITE.com/{vb:link thread, {vb:raw thread}, {vb:raw pageinfo_post}}#post{vb:raw post.postid}&layout=button_count&show_faces=true&width=450&action=like&colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:px"></iframe> <!-- / Facebook Like --> The VBSEO team has instructions on how to make this work for their product here http://www.vbseo.com/f2/facebook-lik...95/#post265997 =========================================== Option 2 (different from above, do not use together) will show at top, see screenshot #3 In Postbit (or legacy) find: Code:
{vb:raw ad_location.thread_first_post_content} Code:
<vb:if condition="(THIS_SCRIPT == showthread) AND ($post[postcount] == '1')" <!-- Facebook Like --> <iframe src="http://www.facebook.com/plugins/like.php?href=http://www.YOURSITE.com/{vb:link thread, {vb:raw thread}}&layout=standard&show_faces=true&width=450&action=like&font=tahoma&colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:75px"></iframe> <!-- / Facebook Like --> </vb:if> ================================================= For those who have asked, here is the modification adds both the "Like" button and comments to a users profile https://vborg.vbsupport.ru/showthread.php?t=239424 ================================================= Additional locations to place this code: For CMS, in vbcms_content_article_page add the code below this: Code:
{vb:raw comment_block} Code:
{vb:raw picturecomment_commentarea} Download Now
Screenshots
Show Your Support
|
Comments |
#112
|
|||
|
|||
![]() Quote:
EDIT: and rockstarnetworks code isn't working either. Also, any idea how to get it working in blogs? |
#113
|
|||
|
|||
![]()
How do i get this for my articles and user blogs (cms)
that makes even more sense than just in the forum... |
#114
|
||||
|
||||
![]() Quote:
|
#115
|
|||
|
|||
![]()
But when you add this to a vbcms article, the link that is posted on Facebook is the one to vBCms Comments forum, not the article itself. Is there a way to fix this?
|
#116
|
||||
|
||||
![]()
See my post #110 above to fix this.
|
#117
|
|||
|
|||
![]()
Thank you, that worked like a charm!
![]() |
#118
|
|||
|
|||
![]()
Hey great Mod. I want to use this on my blog, but I think I need to modify the code?
I tried to use the post bit legacy version and did this: <!-- Facebook Like --> <iframe src="http://www.facebook.com/plugins/like.php?href=http://www.YOURSITE.com/{vb:link blog, {vb:raw blog}}&layout=standard&show_faces=true&wid th=450&action=like&font=tahoma&colorsc heme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:75px"></iframe> <!-- / Facebook Like --> Using this code it posts to facebook however the title is wrong, and it doesn't go to the specific blog, but rather all of the users blogs. Is there a way to use the PostBit Legacy version you posted of the mod but make it work for blogs in the exact same way? (ie. posts blog title on FB and connects to the right blog?). I know your other mod where you add the FB comment box has a "like" button that accomplishes this. I would like that basically without the cumbersome comment box (only like button). Thanks in advance. |
#119
|
||||
|
||||
![]()
How can i add this to my CMS 2 ?
|
#120
|
||||
|
||||
![]()
This code can be used pretty much anywhere, so it's just a matter of finding a location in your template for it. Not sure about CMS2 but what I normally do is find the template then look for keywords on the page that correspond to that template for placement ideas.
|
#121
|
||||
|
||||
![]()
ok and another question i am traying to make a Like Box from facebook as a widget at my web site (www.fmsas.org) by using this code :
Quote:
|
![]() |
Thread Tools | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|