vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   Miscellaneous Hacks - Add New Facebook "Like" Button to Threads and OpenGraph to Headinclude Automatically (https://vborg.vbsupport.ru/showthread.php?t=242536)

6piston 05-31-2010 08:26 AM

1 Attachment(s)
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

kall 05-31-2010 07:08 PM

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.)

ceho 05-31-2010 07:20 PM

Uhm, would it be too much to give me an idea how to do this...? Sorry... And thanks!

MagicThemeParks 05-31-2010 10:15 PM

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 :up:

6piston 06-01-2010 07:52 AM

Quote:

Originally Posted by kall (Post 2046167)
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!!!

kall 06-01-2010 08:12 AM

Find this in the ogfb_like_metadata template, and change the bit in the "" to whatever you want:

PHP Code:

<meta property="og:image" content="$stylevar[titleimage]/> 


ceho 06-01-2010 05:05 PM

1 Attachment(s)
I am suddenly getting errors without having changed anything!!

When you click on the button it says "Be the first one to like: Error".

Erros is a link, when you click it a popup opens saying the page could not be reached. Pls. see screenshot.

Attachment 117870

Any ideas what that is, why it happens out of nowhere and how to fix it?

Thanks a lot!

Edit: OK, it looks this is a Firefox issue. It works on IE, Opera and Google Chrome!
Second edit: a user just reported it happend on IE as well :-(


@MagicThemeParks: thank you very much, I will give it a try once my problem as above is sloved ;-).

kall 06-01-2010 07:13 PM

I'm thinking that the temporary error without changing anything scenario has to be at the FB end. A few people mention it over on the FB developers forums.

See if it comes right in an hour or 2. :)

ps2wiz 07-09-2010 04:36 AM

Could you please instruct me on an example where to place the "$ogfb_like_showthread" code so it appears just as in your screen shot?

Also, whenever a user uses the feature to post it on their profile it automatically grabs an image off the thread. Can I control which image is posted, I don't wish for this part to be automatic. I'd like to inset my forum's logo.

Thanks

Mark.B 08-12-2010 09:54 PM

Installed this, it's the third Facebook Like hack I have tried and this one works better than the others, I have tweaked and played about as I always do and finally worked in a tidy placement of the Like button, top and bottom of thread, with correct alignment.

Example:
http://www.bowlandcentral.com/forum/...ad.php?t=86622

Kwikms 08-13-2010 10:19 PM

I try to show this button only in the first post without success. How can I do that?

Mark.B 08-13-2010 11:28 PM

You could try wrapping it in this conditional, in the postbit or postbit_legacy templates, not sure if it can be called there or not though as I haven't tried it.

Code:

<if condition="$post['isfirstshown']">$ogfb_like_showthread</if>

Kwikms 08-15-2010 11:01 AM

Thanks.

I am just not able to put the like button any where else except in the showthread. It just dont show up. And it doesnt matter what I put in the plugin "OpenGraph/Facebook Integration - SHOWTHREAD variables". I can switch it to whatever I want (postbit_start e.g.) it still shows up in showthread but not in postbit_legacy.

Weird.

Mark.B 08-16-2010 06:13 AM

Quote:

Originally Posted by Kwikms (Post 2084175)
Thanks.

I am just not able to put the like button any where else except in the showthread. It just dont show up. And it doesnt matter what I put in the plugin "OpenGraph/Facebook Integration - SHOWTHREAD variables". I can switch it to whatever I want (postbit_start e.g.) it still shows up in showthread but not in postbit_legacy.

Weird.

It's not weird, it's that the variable mustn't be available in the postbit templates.

There'll be a way round this, I'm just not sure what it is.

benFF 09-15-2010 06:45 AM

Installed and works great :) I just wondered if there is any to get a list of all the "liked" threads somehow in FB.

Insights doesn't like my site application right now, or maybe that's because it hasn't been used enough?

Chase 02-25-2011 08:34 PM

What's the difference between this? http://developers.facebook.com/docs/.../plugins/like/

Edgespeeder06 02-26-2011 03:00 AM

Very cool, any updates on this? In you original post, how did you get the fully custom profile page seen here? http://www.nzboards.com/members/kall/


I would like to set that up for www.NJStangers.org since I already have the Facebook Login bridge going.

Thanks! :)

wicked80 02-26-2011 05:59 PM

Quote:

Originally Posted by Mark.B (Post 2084631)
It's not weird, it's that the variable mustn't be available in the postbit templates.

There'll be a way round this, I'm just not sure what it is.

Same issue, working in SHOWTHREAD but not in postbit_legacy...
any workaround guys to make it work in postbit_legacy???

Thanks

moreilly 03-28-2011 03:10 PM

Can anyone explain to me or help me fix why after you "like" a post when I visit Facebook it has some random image next to it on my wall?

Sometimes it grabs a smiley face, or some random icon placed on my site.

Is there a way to make the image the same?

moreilly 03-28-2011 04:08 PM

nvm, got that sorted.

Now I am a little undecided on where this button needs to go.

Anyone have some examples of where you guys have your button with this hack?

If you do, could you post which template and the code where you integrated it?


All times are GMT. The time now is 01:34 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01104 seconds
  • Memory Usage 1,767KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)bbcode_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (20)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete