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

  #16  
Old 16 May 2010, 20:38
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
And this is why Kall hates the 3.8 Product Creation method. Settings don't pull unless you are in Debug mode? What's up with that?

The settings should be back in the xml, my apologies.
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #17  
Old 17 May 2010, 15:38
SamirDarji SamirDarji is offline
 
Join Date: Apr 2004
This looks very interesting. Subscribing to watch thread.
__________________
Pics of the Huntsville Car Scene: www.huntsvillecarscene.com, hsv.streetracing.org
Pics of the Huntsville Night Life: www.thetoe.cc
Reply With Quote
  #18  
Old 17 May 2010, 16:03
staticrebelle staticrebelle is offline
 
Join Date: Jul 2004
Great stuff!

Is it possible to release a vbSEO version for 3.8.4? Right now the box is just showing up with blank white space inside.
Reply With Quote
  #19  
Old 17 May 2010, 18:09
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Originally Posted by staticrebelle View Post
Great stuff!

Is it possible to release a vbSEO version for 3.8.4? Right now the box is just showing up with blank white space inside.
That's weird.. this mod was developed on a 3.8 forum running vBSEO.

Could you maybe provide a link to a page where it's like that, or the source code of the area?
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #20  
Old 17 May 2010, 18:30
Brandon Sheley's Avatar
Brandon Sheley Brandon Sheley is offline
 
Join Date: Mar 2005
Real name: Brandon
Originally Posted by kall View Post
That's weird.. this mod was developed on a 3.8 forum running vBSEO.

Could you maybe provide a link to a page where it's like that, or the source code of the area?
could you check out my question about adding this in the postbit template


and how do we get our ID's
FB - Page Admins - A comma-separated list of the Facebook IDs of the Admins of your pages on Facebook.
my account is facebook.com/username/
__________________

Love and support one another #vote2020
I offer Managed IT Services in Kansas

Last edited by Brandon Sheley; 17 May 2010 at 18:38.
Reply With Quote
  #21  
Old 17 May 2010, 18:39
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Originally Posted by Loco.M View Post
could you check out my question about adding this in the postbit template


and how do we get our ID's
FB - Page Admins - A comma-separated list of the Facebook IDs of the Admins of your pages on Facebook.
my account is facebook.com/username/
Sorry dude, that super important request to cache two templates took precedence.

When you say postbit, do you mean every post, or are you going to conditional it to only appear in the first one (the reason it is in navbar is because the entire purpose of the Like button under current functionality is to Like the *page* that one is visiting. Putting it in a single post will result in multiple Like URLs for the resource (as that post can be visited via showpost.php or showthread.php among others), and putting it in every post won't work at all on showthread.php)?
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #22  
Old 17 May 2010, 18:40
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
The ID is (as it should mention in the AdminCP bit) found by mousingover your avatar (usually, works for me anyway), or going into your Albums and looking for the common string of numbers that appears on each.
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #23  
Old 17 May 2010, 18:42
Brandon Sheley's Avatar
Brandon Sheley Brandon Sheley is offline
 
Join Date: Mar 2005
Real name: Brandon
I understand, no rush on my part
I have the first post conditioned out in the postibit template (see example)
This version seems to take a while to load, I may just revert back and use the small "like" button/count.

thx, found my ID
__________________

Love and support one another #vote2020
I offer Managed IT Services in Kansas
Reply With Quote
  #24  
Old 17 May 2010, 18:57
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Re it being slow: Conversation here seems to indicate using the FBML makes it faster than the iframe version: http://wiki.developers.facebook.com/...Talk:Fb:iframe

It should be possible to change the button to use the iframe though, keeping all the opengraph stuff.

In ogfb_like_showthread, delete everything and replace with this:


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

Obviously though, by doing this we lose the app_id detail. Let me know how it works for you.
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #25  
Old 17 May 2010, 19:33
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
To make the button display on other templates

Change the hook that the OpenGraph/Facebook Integration - SHOWTHREAD variables plugin executes on to an applicable hook.

(postbit - postbit_display_complete. or chuck it in global_start or something that's called on every page.)
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #26  
Old 17 May 2010, 19:58
Brandon Sheley's Avatar
Brandon Sheley Brandon Sheley is offline
 
Join Date: Mar 2005
Real name: Brandon
Thanks, checking it out now

still not working, I'll play around with this tonight

thx for the help Kall
__________________

Love and support one another #vote2020
I offer Managed IT Services in Kansas
Reply With Quote
  #27  
Old 17 May 2010, 20:07
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
How's it not working man? Gimme a URL.

There is the issue of 'vBSEO needs to use slightly different code' and 'Brandon made me change my plugins while I had the flu' clouding the waters somewhat.
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
Reply With Quote
  #28  
Old 18 May 2010, 03:18
Brandon Sheley's Avatar
Brandon Sheley Brandon Sheley is offline
 
Join Date: Mar 2005
Real name: Brandon
Originally Posted by kall View Post
and 'Brandon made me change my plugins while I had the flu' clouding the waters somewhat.
aww, sorry man
hope you get feeling better
I posted a link a few post up

I'll play with it again, but I had tried placing the $ogfb_like_showthread in my postbit template along with the digg, twitter and stumble one
and tried changing the hook location to the 2 you suggested and nothing showed.
I moved $ogfb_like_showthread back in the showthread template, and it shows.

I just about have it how I want it, thanks for the help
__________________

Love and support one another #vote2020
I offer Managed IT Services in Kansas

Last edited by Brandon Sheley; 18 May 2010 at 03:34.
Reply With Quote
  #29  
Old 18 May 2010, 16:14
staticrebelle staticrebelle is offline
 
Join Date: Jul 2004
Originally Posted by kall View Post
That's weird.. this mod was developed on a 3.8 forum running vBSEO.

Could you maybe provide a link to a page where it's like that, or the source code of the area?
Hope this helps

http://www.avrilbandaids.com/forums/...ound-site.html

You can see the white box above the reply button.
Reply With Quote
  #30  
Old 18 May 2010, 18:29
kall's Avatar
kall kall is offline
 
Join Date: Apr 2004
Real name: Ace
Ahh. One question - are you currently running YAFB or the default 4.0.3 Facebook Connect?

They're not compatible You would need to use the iframe code rather than the FBML version.
__________________
vBulletin Styles (All styles compatible with 3.8.4 - Steel Blue 4.0 Available) | vBulletin Hosting
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:35.

Layout Options | Width: Wide Color: