Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Add New Facebook "Like" Button to Threads and OpenGraph to Headinclude Automatically Details »
Add New Facebook "Like" Button to Threads and OpenGraph to Headinclude Automatically
Mod Version: 0.2.1, by kall (Coder) kall is offline
Developer Last Online: Mar 2021 I like it Show Printable Version Email this Page

vB Version: 3.8.4 Rating: (1 vote - 4.00 average) Installs: 25
Released: 15 May 2010 Last Update: 16 May 2010 Downloads: 201
Not Supported Uses Plugins Template Edits External Content Is in Beta Stage  

From The Open Graph Protocol :
The Open Graph protocol enables any web page to become a rich object in a social graph. For instance, this is used on Facebook to enable any web page to have the same functionality as a Facebook Page.
Basic metadata
To turn your web pages into graph objects, you need to add basic metadata to your page. We've based the initial version of the protocol on RDFa which means that you'll place additional <meta> tags in the <head> of your web page. The four required properties for every page are:

og:title - The title of your object as it should appear within the graph, e.g., "The Rock".
og:type - The type of your object, e.g., "movie". Depending on the type you specify, other properties may also be required.
og:image - An image URL which should represent your object within the graph.
og:url - The canonical URL of your object that will be used as its permanent ID in the graph, e.g., "http://www.imdb.com/title/tt0117500/".
This modification will add these tags to all pages, and the <og:title> attribute to your SHOWTHREAD pages (for the moment.. additional Pages to be added soon), along with the Facebook 'Like Button' under the Thread Title (as we are supposed to put the Like button next to the thing the person is Liking).

Install Instructions:
AdminCP - Plugins & Products - Manage Products - [Add/Import Product] , browse to the location of the .xml file you downloaded from this thread, Import it.
Template Modifications
In SHOWTHREAD, find:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Find:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Add under:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Wherever you want to add the Like Button, add

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Configuration Instructions
AdminCP - Settings - Options - Opengraph/Facebook Integration
Global On/Off - Set to Yes to turn the system on.
FB - Page Admins - A comma-separated list of the Facebook IDs of the Admins of your pages on Facebook.
FB - App ID - The application ID of your Facebook Application.
OG - Site Name - A short, human-readable name for your site that will appear in the Like on the User's Facebook Activity Stream.

It is important to fill in these, as they are used by FB to fill in some of the information, and allows your pages (Showthread at the moment) to be referenced in the Open Graph.

What's Next?
This is an early beta release to gauge the interest in Open Graph/Facebook type stuff.
I intend to add the tags to other pages, and implement some of the other Facebook Social Plugins. These will all be On/Off configurable. Some can be seen in action at:

View Profile: kall - New Zealand Boards - Like for Member Profiles
http://www.nzboards.com/the-lounge/r...on-sale-90544/ - Activity and Recommendation Streams in first and last post.

(4.0.3 Version here: http://www.vbulletin.org/forum/showthread.php?t=242525)

Download Now

Only licensed members can download files, Click Here for more information.

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Similar Mod
Mod Developer Type Replies Last Post
Integration with vBulletin Add New Facebook "Like" Button and Social Plugins (and OpenGraph to Headinclude) kall vBulletin 4.x Add-ons 91 20 Feb 2012 18:01

  #31  
Old 19 May 2010, 15:57
Brandon Sheley's Avatar
Brandon Sheley Brandon Sheley is offline
 
Join Date: Mar 2005
Real name: Brandon
This stopped working when I tried to isntall the vb nexius mod
I've removed both, re-added this mod and nothing is showing in the postbit.
I'll see if I can look deeper, maybe something from the nexius mad is stalling things..
I'm bummed, it was looking great too
__________________

Love and support one another #vote2020
I offer Managed IT Services in Kansas
Reply With Quote
  #32  
Old 19 May 2010, 18:45
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Are you still using some form of Connect?
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #33  
Old 20 May 2010, 13:27
Brandon Sheley's Avatar
Brandon Sheley Brandon Sheley is offline
 
Join Date: Mar 2005
Real name: Brandon
Originally Posted by kall View Post
Are you still using some form of Connect?
well I wasn't, your mod was working great and then I tried adding the nexius mod that IB_username (I don't remember his name, but it's the IB guy that's posted a few mods) and your mod stopped working. So I removed the nexius mod, removed all files and your mod still doesn't work
I've since removed the opengraph mod, and tried adding it back late last night.. still not working
I'm guessing there is something leftover from the nexius mod

your mod doesn't even show ATM if I place it in the showthread template like designed.
__________________

Love and support one another #vote2020
I offer Managed IT Services in Kansas
Reply With Quote
  #34  
Old 29 May 2010, 09:12
ceho ceho is offline
 
Join Date: Mar 2008
Real name: Chris
I tried your mod and it's working for me, thanks a lot. However it is showing a white rectangle around the button and my forum is dark. Is there any chance to adapt the look and colors etc. of the rectangle? Thanks a lot!
__________________
www.cureconnections.com
Reply With Quote
  #35  
Old 29 May 2010, 09:42
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Originally Posted by ceho View Post
I tried your mod and it's working for me, thanks a lot. However it is showing a white rectangle around the button and my forum is dark. Is there any chance to adapt the look and colors etc. of the rectangle? Thanks a lot!
Sure is.

In template ogfb_like_showthread, change the following div properties to suit.

<div style="padding: 5px; border: 1px solid #3F6F81; background: #ffffff; font-size: 10px; width: 300px;">
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #36  
Old 29 May 2010, 15:39
ceho ceho is offline
 
Join Date: Mar 2008
Real name: Chris
Awesome, thanks for the quick reply!
__________________
www.cureconnections.com
Reply With Quote
  #37  
Old 29 May 2010, 20:24
yamahapaul's Avatar
yamahapaul yamahapaul is offline
 
Join Date: Aug 2008
Real name: Paul
Question

I've downloaded this, tried it, got it working ok and experimented with moving the like button around, however the place I'd like it ideally is one of these two positions in the attached pics (blue cross marked) the first one is my preference... any ideas at all please?
Attached Images
File Type: jpg Capture 1.jpg (85.3 KB, 55 views)
File Type: jpg Capture.jpg (95.1 KB, 44 views)
__________________
midlands heritage
Reply With Quote
  #38  
Old 29 May 2010, 20:44
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Originally Posted by yamahapaul View Post
I've downloaded this, tried it, got it working ok and experimented with moving the like button around, however the place I'd like it ideally is one of these two positions in the attached pics (blue cross marked) the first one is my preference... any ideas at all please?
You could try adding $ogfb_like_showthread before the following in SHOWTHREAD:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #39  
Old 29 May 2010, 22:22
yamahapaul's Avatar
yamahapaul yamahapaul is offline
 
Join Date: Aug 2008
Real name: Paul
Originally Posted by kall View Post
You could try adding $ogfb_like_showthread before the following in SHOWTHREAD:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.
No, that doesnt work... arrrghh I can get it everywhere except where I want it lol
__________________
midlands heritage
Reply With Quote
  #40  
Old 30 May 2010, 16:47
ceho ceho is offline
 
Join Date: Mar 2008
Real name: Chris
Is there any chance to exclude the button from private forums?
__________________
www.cureconnections.com
Reply With Quote
  #41  
Old 31 May 2010, 09:26
6piston's Avatar
6piston 6piston is offline
 
Join Date: Apr 2005
hi kall

thanks for the mod,
got it working

some questions about thumbnails:
For threads i like without commenting : profile shows likes
For threads i like with my comment : profile shows snippet of thread + thumbnail

the weird thing is for all the thumbnail that appears beside the like post that displays on facebook, it shows a thumbnail of an image that isn't in the page. i attached the screen shot.

i have no idea what VBCUSTOMPIXEL is

Is there a way i can set a permanent thumbnail image instead? if there is no way of determining a thumnail from the thread?

Thanks!


thanks
Attached Images
File Type: jpg 1.jpg (25.2 KB, 35 views)
Reply With Quote
  #42  
Old 31 May 2010, 20:08
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
The image that FB displays comes from og:url .. I'm not sure where it pulls those weird non-existant images from, but it does that when the og:url is not defined.

I could really only define it for Member Profiles, otherwise I set it to whatever you have set for the titleimage stylevar.

(Regarding the private forums exclusion, yes.. you would just have to add the conditional to exclude it.)
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #43  
Old 31 May 2010, 20:20
ceho ceho is offline
 
Join Date: Mar 2008
Real name: Chris
Uhm, would it be too much to give me an idea how to do this...? Sorry... And thanks!
__________________
www.cureconnections.com
Reply With Quote
  #44  
Old 31 May 2010, 23:15
MagicThemeParks's Avatar
MagicThemeParks MagicThemeParks is offline
 
Join Date: Sep 2009
ceho, you could search on how to exclude based on certain conditionals.

Google search brought me an article over at vBulletinSetup.com here: http://forum.vbulletinsetup.com/f18/...list-2185.html

Good luck
Reply With Quote
  #45  
Old 01 Jun 2010, 08:52
6piston's Avatar
6piston 6piston is offline
 
Join Date: Apr 2005
Originally Posted by kall View Post
The image that FB displays comes from og:url .. I'm not sure where it pulls those weird non-existant images from, but it does that when the og:url is not defined.

I could really only define it for Member Profiles, otherwise I set it to whatever you have set for the titleimage stylevar.

(Regarding the private forums exclusion, yes.. you would just have to add the conditional to exclude it.)
hi Kall

thanks for the reply
can you tell me very briefly where to set this url to use a single image instead?

thanks!!!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 20:20.

Layout Options | Width: Wide Color: