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)
-   -   Show Thread Enhancements - [AJAX] Post Thank You Hack (https://vborg.vbsupport.ru/showthread.php?t=165673)

Manipulation 04-01-2017 03:27 PM

Bump, does anybody have a solution to the page freezing when I upload the plug in?

Manipulation 04-08-2017 01:58 AM

Can I get some assistance with this? Anybody?

Don Z. 05-21-2017 12:03 PM

I'll bump this since I'm having the exact same problem. After upgrading to vB 3.8.11 pages just freeze when Post Thank You Hack 7.7 is enabled.

Does anyone know how to get this working again? I have thousands of "Thanks" I don't want to lose.

vbem2 05-23-2017 06:11 PM

Quote:

Originally Posted by blind-eddie (Post 2583617)
Would have a better idea if you were to post your database error in [CODE] brackets.

Also just upgraded to 3.8.11 and am getting errors on showthread.php when the Thanks plugin is enabled.

Seems to be related to an array variable that doesn't exist after the upgrade.

Code:

Database error in vBulletin 3.8.11:

Invalid SQL:
SELECT * FROM post_thanks AS post_thanks INNER JOIN user AS user USING (userid) WHERE post_thanks.postid IN (0Array) ORDER BY post_thanks.username ASC;

MySQL Error  : Unknown column '0Array' in 'where clause'
Error Number  : 1054
Request Date  : Tuesday, May 23rd 2017 @ 03:57:59 PM
Error Date    : Tuesday, May 23rd 2017 @ 03:57:59 PM
Script        : ....../forum/showthread.php?t=33292
Classname    : vB_Database_MySQLi
MySQL Version : 5.5.54-0+deb8u1


treki 05-24-2017 06:41 PM

Same problem. After upgrading to 3.8.11:

Code:

Invalid SQL:
SELECT * FROM vb_post_thanks AS post_thanks INNER JOIN vb_user AS user USING (userid) WHERE post_thanks.postid IN (0Array) ORDER BY post_thanks.username ASC;

MySQL Error  : Unknown column '0Array' in 'where clause'
Error Number  : 1054

Any ideas/solutions?

cassedy 05-26-2017 12:57 PM

same error here after upgrade to 3.8.11.

any idea?

vbem2 05-26-2017 03:58 PM

Making the following changes caused the Post Thanks hack to start working again on my 3.8.11 installation. Note: I haven't tested extensively beyond seeing that I could give thanks and delete it from one other member's post.

GIANT DISCLAIMER: I am not an expert coder. I occasionally muck around in PHP and sometimes understand what I'm doing.

Apply this fix AT YOUR OWN RISK. I can't help if it doesn't work for you.

The changes below refer to Post Thank You Hack version 7.6 only.

1) Back up a copy of your original 7.6 file in /forum/includes/functions_post_thanks.php in case this gets all screwed up.

2) Open the file in your favourite editor.

3) Starting at line 178, replace this...

Code:

                if ($postids)
                {
                        $post_ids = "0$postids";
                }
                else
                {
                        $post_ids = $postid;
                }

... with this:

Code:

                if (empty($postids))
                {
                        $postids[] = $postid;
                }

4) A few lines below that (originally at line 189, but moved down due to the changes above), replace the this line ...

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks AS post_thanks INNER JOIN " .TABLE_PREFIX. "user AS user USING (userid) WHERE post_thanks.postid IN (" . $post_ids . ") ORDER BY post_thanks.username ASC");
... with this:

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks AS post_thanks INNER JOIN " .TABLE_PREFIX. "user AS user USING (userid) WHERE post_thanks.postid IN (" . implode(',', $postids) . ") ORDER BY post_thanks.username ASC");
5) A few lines below that (originally at line 193, but since moved further down due to the changes above), replace the this line ...

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks WHERE postid IN (" . $post_ids . ") ORDER BY username ASC");
... with this:

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks WHERE postid IN (" . implode(',', $postids) . ") ORDER BY username ASC");
6) Save & upload the file to /forum/includes.

Maybe it'll work for you too. Good luck!

cassedy 05-26-2017 04:30 PM

Quote:

Originally Posted by vbem2 (Post 2586995)
Making the following changes caused the Post Thanks hack to start working again on my 3.8.11 installation. Note: I haven't tested extensively beyond seeing that I could give thanks and delete it from one other member's post.

GIANT DISCLAIMER: I am not an expert coder. I occasionally muck around in PHP and sometimes understand what I'm doing.

Apply this fix AT YOUR OWN RISK. I can't help if it doesn't work for you.

The changes below refer to Post Thank You Hack version 7.6 only.

1) Back up a copy of your original 7.6 file in /forum/includes/functions_post_thanks.php in case this gets all screwed up.

2) Open the file in your favourite editor.

3) Starting at line 178, replace this...

Code:

                if ($postids)
                {
                        $post_ids = "0$postids";
                }
                else
                {
                        $post_ids = $postid;
                }

... with this:

Code:

                if (empty($postids))
                {
                        $postids[] = $postid;
                }

4) A few lines below that (originally at line 189, but moved down due to the changes above), replace the this line ...

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks AS post_thanks INNER JOIN " .TABLE_PREFIX. "user AS user USING (userid) WHERE post_thanks.postid IN (" . $post_ids . ") ORDER BY post_thanks.username ASC");
... with this:

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks AS post_thanks INNER JOIN " .TABLE_PREFIX. "user AS user USING (userid) WHERE post_thanks.postid IN (" . implode(',', $postids) . ") ORDER BY post_thanks.username ASC");
5) A few lines below that (originally at line 193, but since moved further down due to the changes above), replace the this line ...

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks WHERE postid IN (" . $post_ids . ") ORDER BY username ASC");
... with this:

Code:

                        $thanks = $vbulletin->db->query_read("SELECT * FROM " .TABLE_PREFIX. "post_thanks WHERE postid IN (" . implode(',', $postids) . ") ORDER BY username ASC");
6) Save & upload the file to /forum/includes.

Maybe it'll work for you too. Good luck!

genius! it works.. thanks a lot..:)

treki 05-26-2017 06:42 PM

YEEEES!!!! Genius. 7.7 work fine under vB3.8.11

Silvio 07-05-2017 07:28 AM

@vbem2 thank you! It fixed to me too! great work.

Celli0905 07-18-2017 11:44 AM

Quote:

Originally Posted by treki (Post 2586999)
YEEEES!!!! Genius. 7.7 work fine under vB3.8.11

Same here ... many thanks for the help :)

Cheers,
Flounder

Peter Walker 08-30-2017 08:19 PM

I have just starting to use this hack after migrating my forum from 3.8.9 to 5.3.2.

I was previously using Abel's Post Thank You Hack.

Is there any way of importing the existing "thanks" into the new system?
How do I make vBulletin's Like button disappear in 5.3.2?

keharris53 11-20-2017 05:09 PM

1 Attachment(s)
Curious to know if anybody knows how to change this phrase:
The Following User Says Thank You to (username removed) For This Useful Post:

I've tried searching for this phrase with no luck, but still trying. Thanks.

Ken

Disregard, found the phrases! For my forums preferred "Like" and changed button to match the others.

blind-eddie 11-20-2017 09:47 PM

Quote:

Originally Posted by keharris53 (Post 2591183)
Curious to know if anybody knows how to change this phrase:
The Following User Says Thank You to (username removed) For This Useful Post:

I've tried searching for this phrase with no luck, but still trying. Thanks.

Ken

Disregard, found the phrases! For my forums preferred "Like" and changed button to match the others.

If you did not know about this, here is a great edit for his addon.:up::up:

https://vborg.vbsupport.ru/showthread.php?t=266358

Joshua2597 12-17-2017 04:04 PM

I am having issues with 3.8.11 says there is a database error?

Mark.B 12-19-2017 12:09 PM

Quote:

Originally Posted by Joshua2597 (Post 2591675)
I am having issues with 3.8.11 says there is a database error?

We need to know what the database error is.

G225 12-22-2017 04:17 AM

Dont work for me. Not appear on theme. 3.8.11

ano2k77 01-25-2018 07:47 PM

Anyone know why when I enable this plugin on my vBulletin 3.8.9 - when I try and view or create a thread, I get a http 500 error? Yet when it's disabled, no problems at all? I've been in touch with my host all day and we've tried everything but we're not sure what else it could be?

ano2k77 02-02-2018 11:50 PM

Quote:

Originally Posted by Mark.B (Post 2591698)
We need to know what the database error is.

Database error in vBulletin 3.8.11:

Invalid SQL:
SELECT * FROM post_thanks AS post_thanks INNER JOIN user AS user USING (userid) WHERE post_thanks.postid IN (0Array) ORDER BY post_thanks.username ASC;

MySQL Error : Unknown column '0Array' in 'where clause'

I'm getting this when I install for 3.8.11

MaiThamDobais 03-12-2018 07:34 PM

Quote:

Originally Posted by ano2k77 (Post 2592651)
Database error in vBulletin 3.8.11:

Invalid SQL:
SELECT * FROM post_thanks AS post_thanks INNER JOIN user AS user USING (userid) WHERE post_thanks.postid IN (0Array) ORDER BY post_thanks.username ASC;

MySQL Error : Unknown column '0Array' in 'where clause'

I'm getting this when I install for 3.8.11

Same as you !!

moledj 03-23-2018 04:58 PM

change includes/functions_post_thanks.php line 180 from:

$post_ids = "0$postids";

to

$post_ids = is_array($postids) ? implode(',',$postids) : "0$postids";

mehedimw 07-28-2018 12:11 PM

Quote:

Originally Posted by moledj (Post 2593709)
change includes/functions_post_thanks.php line 180 from:

$post_ids = "0$postids";

to

$post_ids = is_array($postids) ? implode(',',$postids) : "0$postids";

Problem solved thx bro

Mandushi 06-19-2019 03:42 AM

Quote:

Originally Posted by moledj (Post 2593709)
change includes/functions_post_thanks.php line 180 from:

$post_ids = "0$postids";

to

$post_ids = is_array($postids) ? implode(',',$postids) : "0$postids";

Thnx brother

oldengine 08-25-2019 09:54 PM

Database error in vBulletin 3.8.11 on PHP 7.1.30 MySQL 5.6.45
Invalid SQL:
SELECT * FROM post_thanks WHERE postid IN (0Array) ORDER BY username ASC;

MySQL Error : Unknown column '0Array' in 'where clause'
Error Number : 1054
Request Date : Sunday, August 25th 2019 @ 11:41:49 PM
Error Date : Sunday, August 25th 2019 @ 11:41:49 PM
Script : http://www.smokstak.com/forum/showth...99237&posted=1
Referrer : https://www.smokstak.com/forum/newre...eply&p=1599222
IP Address : 47.199.66.226
Username : Harry
Classname : vB_Database_MySQLi
MySQL Version : 5.6.45-log
Server : 192.252.219.187
User Agent :

Dave 08-25-2019 10:02 PM

Quote:

Originally Posted by oldengine (Post 2600385)
Database error in vBulletin 3.8.11 on PHP 7.1.30 MySQL 5.6.45
Invalid SQL:
SELECT * FROM post_thanks WHERE postid IN (0Array) ORDER BY username ASC;

MySQL Error : Unknown column '0Array' in 'where clause'
Error Number : 1054
Request Date : Sunday, August 25th 2019 @ 11:41:49 PM
Error Date : Sunday, August 25th 2019 @ 11:41:49 PM
Script : http://www.smokstak.com/forum/showth...99237&posted=1
Referrer : https://www.smokstak.com/forum/newre...eply&p=1599222
IP Address : 47.199.66.226
Username : Harry
Classname : vB_Database_MySQLi
MySQL Version : 5.6.45-log
Server : 192.252.219.187
User Agent :

Fix is posted 3 posts above you.
https://vbulletin.org/forum/showpost...postcount=2381

lange 08-26-2019 09:04 AM

12 years later, this mod still works.

oldengine 08-27-2019 04:19 AM

Quote:

Originally Posted by Dave (Post 2600386)

ABSOLUTELY FANTASTIC! Thank you moledj - a lot of users really appreciate this hack!

Thank you, Dave, for opening my eyes!

ShikiSuen 01-02-2020 12:40 PM

Folks, this plugin supports PHP 7.4 as long as you follow PHP warnings to fix constant names to make sure they are quoted.

lange 01-02-2020 02:49 PM

Quote:

Originally Posted by ShikiSuen (Post 2601646)
Folks, this plugin supports PHP 7.4 as long as you follow PHP warnings to fix constant names to make sure they are quoted.

Right ! :up:

Including the following plugins/addons :
[hide] hack incl post thank you "addon" : https://vborg.vbsupport.ru/showthread.php?t=130887

Recent Thanks for [AJAX] Post Thank You Hack : https://vborg.vbsupport.ru/showthread.php?t=279907

AKadoorah 03-28-2020 03:35 AM

Hello folks,

I've switched my PHP from 5.3 to 7.1, after doing so, I've faced an issue:
Code:

Error: [] operator not supported for strings in ..../includes/functions_post_thanks.php on line 180
Trace Data:
#1 : vbstop() called in ..../includes/class_core.php on line 3834
#2 : vbulletin_exception_handler() called in  on line

Var Type:
[ NULL ]

Var Data:
null

For ur information I'm running vb 3.8.11, so is there any solution for this issue?

PinkMilk 03-29-2020 08:49 AM

Quote:

Originally Posted by AKadoorah (Post 2602394)
Hello folks,

I've switched my PHP from 5.3 to 7.1, after doing so, I've faced an issue:
Code:

Error: [] operator not supported for strings in ..../includes/functions_post_thanks.php on line 180
Trace Data:
#1 : vbstop() called in ..../includes/class_core.php on line 3834
#2 : vbulletin_exception_handler() called in  on line

Var Type:
[ NULL ]

Var Data:
null

For ur information I'm running vb 3.8.11, so is there any solution for this issue?


Problem with: Fatal error: [] operator not supported for strings

AKadoorah 04-01-2020 08:00 AM

Quote:

Originally Posted by PinkMilk (Post 2602403)

To be honest, I don't get it.

PinkMilk 04-01-2020 09:35 PM

Quote:

Originally Posted by AKadoorah (Post 2602438)
To be honest, I don't get it.

https://vborg.vbsupport.ru/showpost....postcount=2381

AKadoorah 04-02-2020 02:58 AM

1 Attachment(s)
Quote:

Originally Posted by PinkMilk (Post 2602446)


Still not working, it appears new issue!

https://vborg.vbsupport.ru/attachmen...1&d=1585803472

yilmaz 05-27-2020 10:04 AM

1 Attachment(s)
includes/functions_post_thanks.php

Upload attached php file to includes folder

php version 7.2
vBulletin 3.8.11
worked smoothly



note: adapted in the same way as [hide] hack incl post thank you "addon"

Hide hack users should download product-sids_hide.xml

dbreh 11-02-2020 12:08 PM

Quote:

Originally Posted by cassedy (Post 2586996)
genius! it works.. thanks a lot..:)

Great answer, it works fine ..

thanks a lot.. :)

docjohn 10-16-2023 10:38 AM

This component in the plugin for postbit_display_start throws an error in PHP 7.3:

Code:

eval('$template_hook[postbit_end] .= " ' . fetch_template('post_thanks_box') . '";');
Error:

Code:

PHP Warning: Use of undefined constant postbit_end - assumed 'postbit_end' (this will throw an Error in a future version of PHP) in ..../includes/class_postbit.php(268) : eval()'d code(23) : eval()'d code on line 1
All you need do is add some quotes around postbit_end:

Code:

eval('$template_hook["postbit_end"] .= " ' . fetch_template('post_thanks_box') . '";');


All times are GMT. The time now is 08:18 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.03115 seconds
  • Memory Usage 1,853KB
  • 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
  • (19)bbcode_code_printable
  • (17)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (37)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