vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=236)
-   -   Add-On Releases - Add "LIKE" button and other Facebook plugins to threads. (https://vborg.vbsupport.ru/showthread.php?t=243319)

Digital Jedi 07-03-2010 05:09 AM

For what it's worth, I've been having problems installing the Like button even before I found this mod. I pretty much did everything they instructed at Facebook before I read the install instructions here, and it appears to be the same problem. "Like" does not like vBulletin threads. At least not vB3 threads.

BirdOPrey5 07-03-2010 03:37 PM

Quote:

Originally Posted by Digital Jedi (Post 2063612)
For what it's worth, I've been having problems installing the Like button even before I found this mod. I pretty much did everything they instructed at Facebook before I read the install instructions here, and it appears to be the same problem. "Like" does not like vBulletin threads. At least not vB3 threads.

I agree this is much more difficult then it should be- something isn't playing nicely in vB... but I did end up getting this to work using all the instructions in this mod but instead if pasting the last step here into the template I used the IFRAME code provided by facebook...

Code:

<iframe src="http://www.facebook.com/plugins/like.php?href=http://www.YOURDOMAIN/forums/showthread.php$session[sessionurl]?t=$threadid" &amp;show_faces=false&amp;width=350&amp;action=like&amp;colorscheme=dark&amp;height=30" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:350px; height:30px;" allowTransparency="true"></iframe>
edit YOURDOMAIN to be your web domain...

Additionally I put it in an if tag:
Code:

<if condition="!in_array($GLOBALS[forumid], array(2, 3, 6, 15, 24, 45))">
 -iframe code-
</if>

Where the numbers are the forum id's of private forums that aren't viewable by guests and therefore useless to add a 'like' button too.

Finally I moved this to under where the page navigation menu would show if it was a multiple page thread on the showthread template... I moved the <td></td> tags out of the built in <if> statement so the table will be there regardless of whether the page nav menu is displayed... the code for everything now looks like:

Code:

        <td align="$stylevar[right]"><if condition="$show['pagenav']">$pagenav</if>
<if condition="!in_array($GLOBALS[forumid], array(2, 3, 6, 15, 24, 45))">
<iframe src="http://www.facebook.com/plugins/like.php?href=http://www.YOURDOMAIN/forums/showthread.php$session[sessionurl]?t=$threadid" &amp;show_faces=false&amp;width=350&amp;action=like&amp;colorscheme=dark&amp;height=30" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:350px; height:30px;" allowTransparency="true"></iframe>
</if>
</td>

Anyway this all works fine (for me), you can see a demo at:
http://www.juot.net/forums/showthread.php?t=41185
No login required.

Xtrigit 07-04-2010 10:03 PM

MOD has been updated, enjoy!

Digital Jedi 07-07-2010 06:46 AM

Quote:

Originally Posted by Xtrigit (Post 2064546)
MOD has been updated, enjoy!

Okay, made the updated changes. Still giving me the iframe error, even though I'm not using an iframe. Really, I don't see any reason why this shouldn't be working. Everything is as Facebook says it should be done.

Digital Jedi 07-07-2010 06:50 AM

Quote:

Originally Posted by Digital Jedi (Post 2065726)
Okay, made the updated changes. Still giving me the iframe error, even though I'm not using an iframe. Really, I don't see any reason why this shouldn't be working. Everything is as Facebook says it should be done.

Looks like we're not the only one's having this problem: http://thecandycrew.webs.com/ http://forum.developers.facebook.com...php?pid=242948

Xtrigit 07-07-2010 08:57 PM

Quote:

Originally Posted by Digital Jedi (Post 2065728)
Looks like we're not the only one's having this problem: http://thecandycrew.webs.com/ http://forum.developers.facebook.com...php?pid=242948

What is your site URL?

I've implemented facebook plugins in dozens of sites and they all seem to be working great.

I believe some javascript on your site is interfering with facebook plugins.

sundarmobiles 07-08-2010 11:55 AM

1 Attachment(s)
can u give the procedure to use navbit area like in this screen shot and also can i use this one for this version 3.7.3?

BirdOPrey5 07-08-2010 03:20 PM

Quote:

*YOUR PROFILE ID = http://www.facebook.com/profile.php?id=randomnumbers
Are these random numbers made up by us or are they generated somewhere? How many digits- does it matter?

BirdOPrey5 07-08-2010 10:24 PM

Quote:

*This will place the Facebook Comment box below the last post, you may change the width to your liking.
*The comment box will only be shown to guests.
Also- why would I only want to show the comment box to guests? Wouldn't I want anyone to be able to make a comment when they Like something?

Xtrigit 07-10-2010 01:58 AM

Quote:

Originally Posted by BirdOPrey5 (Post 2066371)
Are these random numbers made up by us or are they generated somewhere? How many digits- does it matter?

Those numbers are your facebook profile ID, you'll find this in the address bar when you sign in to facebook.

If you have assigned your profile a custom "name", please read this:
http://www.ehow.com/how_5753004_facebook-id.html

Quote:

Originally Posted by BirdOPrey5 (Post 2066562)
Also- why would I only want to show the comment box to guests? Wouldn't I want anyone to be able to make a comment when they Like something?

Replace:
PHP Code:

<br /> 
<!-- 
Facebook Comment --> 
<if 
condition="in_array($bbuserinfo[usergroupid],array(2,6,7,5))"><else /><div align="center"
<
fb:comments numposts="3" width="800"></fb:comments></if></div
<!-- / 
Facebook Comment --> 

With:
PHP Code:

<br /> 
<!-- 
Facebook Comment --> 
<
div align="center"
<
fb:comments numposts="3" width="800"></fb:comments></if></div
<!-- / 
Facebook Comment --> 

Now all members and guests can see and write in the comment box.


All times are GMT. The time now is 06:02 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.03271 seconds
  • Memory Usage 1,759KB
  • 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
  • (3)bbcode_code_printable
  • (2)bbcode_php_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (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