vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=246)
-   -   Show Thread Enhancements - Add New Facebook "Like" button to your threads (https://vborg.vbsupport.ru/showthread.php?t=241011)

kall 04-22-2010 06:25 PM

Quote:

Originally Posted by ericgtr (Post 2025507)
Understood, let's see if we can get this working with VBSEO by presenting this question to them, we need to convert this to VBSEO:
Code:

{vb:link thread, {vb:raw thread}, {vb:raw pageinfo_post}}#post{vb:raw post.postid}
Please see if you can get one of their people to answer this and we can then add a VBSEO version of this mod here.

I've taken the question to the devs.. it's odd. The link shows as the standard vB variable url inside the fb stuff, whether you use iframe or the js version.

Obviously the error is there to prevent people from having what they like link back to the wrong thing, but it's a tad annoying that it doesn't work with the way vbseo does it.

Does it work with the vB4 SEO options?

ericgtr 04-22-2010 06:34 PM

Quote:

Originally Posted by kall (Post 2025522)
I've taken the question to the devs.. it's odd. The link shows as the standard vB variable url inside the fb stuff, whether you use iframe or the js version.

Obviously the error is there to prevent people from having what they like link back to the wrong thing, but it's a tad annoying that it doesn't work with the way vbseo does it.

Does it work with the vB4 SEO options?

I'm afraid I don't have vbseo to test it on so I can't say. But yeah, like you say it checks the URL before it allows it which is good and bad I guess depending on how you look at it. The benefit to me for iframe is that it won't affect the board if it's slow for any reason.

giorgino 04-22-2010 07:13 PM

Quote:

Originally Posted by Da-Vinci (Post 2025516)
Using the code from the 2nd post mine looks like this with VBSEO installed. and I think it's a pretty cool mod.

Obviously I'm using Adsense so it makes more sence to have the like button beneath the title, but I've found no problems with VBSEO.

http://www.hostmypics.org/pictures/4...d39c6288bd.png

One question, I have though is there a conditional, I can use to exclude certain forums?


Great effect! How you have done? Can you give me the code please?

Da-Vinci 04-22-2010 07:32 PM

Yes it's in the 2nd post of this thread.

https://vborg.vbsupport.ru/showpost....32&postcount=2

Maybe the VBSEO problem is to do with the type of url rewrite you use, I use 002 - Hierarchic directory type URLs with content relevant threads (used at www.vBSEO.com) for my forumURL's, but obviously if your using a different type of URL rewrite it's not something you want to change.

Also not wanting to be a pest but can anybody answear this?

Is there a conditional, I can use to exclude certain forums?

The reason being we have a few private forums which I would prefer not to be displayed on Facebook, and although I can tell the members who have access to said forums not to click the Like button in the said sections, you will always get one or two, who will.

hiker 04-22-2010 07:38 PM

Nice mod. Will install it soon. I was waiting for this since the news of Facebook discontinuing the Facebook Connect soon.

Alien 04-22-2010 07:42 PM

On multi-page threads, it will put up the like text/icons at the top of every page.

Less than ideal, I'd like to see it only on page 1/post 1 of a thread...

Quote:

Originally Posted by saviola8x (Post 2025432)
Fix with me ! Demo : http://s2facebook.com/forum/showthread.php?854

Open Postbit temp search
Code:

{vb:raw ad_location.thread_first_post_content}
Add below :
Code:

<!-- Facebook Like -->
<iframe src="http://www.facebook.com/plugins/like.php?href=http://DOMAIN.com/forum/{vb:link thread, {vb:raw thread}}&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;font=tahoma&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:75px"></iframe>
<!-- / Facebook Like -->

Done.


giorgino 04-22-2010 07:58 PM

Quote:

Originally Posted by Da-Vinci (Post 2025550)
Yes it's in the 2nd post of this thread.

https://vborg.vbsupport.ru/showpost....32&postcount=2

Maybe the VBSEO problem is to do with the type of url rewrite you use, I use 002 - Hierarchic directory type URLs with content relevant threads (used at www.vBSEO.com) for my forumURL's, but obviously if your using a different type of URL rewrite it's not something you want to change.

Also not wanting to be a pest but can anybody answear this?

Is there a conditional, I can use to exclude certain forums?

The reason being we have a few private forums which I would prefer not to be displayed on Facebook, and although I can tell the members who have access to said forums not to click the Like button in the said sections, you will always get one or two, who will.

Great work perfectly with vBSeo (with 002 rules like you). Thank you very much! :)

Da-Vinci 04-22-2010 08:03 PM

Cool glad it's worked for you, but I take no credit for any of the work, I just used what was available to me.

ericgtr 04-22-2010 08:05 PM

Quote:

Originally Posted by Alien (Post 2025552)
On multi-page threads, it will put up the like text/icons at the top of every page.

Less than ideal, I'd like to see it only on page 1/post 1 of a thread...

Here's the way around that:

In Postbit (or legacy) find:
Code:

{vb:raw ad_location.thread_first_post_content}
Add this after:
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}}&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;font=tahoma&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:450px; height:75px"></iframe>
<!-- / Facebook Like -->
</vb:if>

This will only show on the first post no matter how many pages there are.

Alien 04-22-2010 08:10 PM

Excellent, eric. Thank you SO much. I'll just add an additional conditional to exclude some forums and we should be all set!


All times are GMT. The time now is 02:48 AM.

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.01413 seconds
  • Memory Usage 1,753KB
  • 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
  • (5)bbcode_code_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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