Quote:
Originally Posted by cmeinck
I'm sure I'm not the only one, so would appreciate any help on how to prevent these database errors. As far as I can tell, there are no visible links to "find thanks".
Code:
Database error in vBulletin 4.0.3:
Invalid SQL:
REPLACE INTO search (userid, ipaddress, personal, searchuser, forumchoice, sortby, sortorder, searchtime, showposts, orderedids, dateline, displayterms, searchhash)
VALUES (0, '66.249.65.181', 1, 'manic', '', 'post.dateline', 'DESC', 0.12551, 1, '351328,351311,348467,348466,346458,346411,344262,342697,342689', 1274289300, 'a:6:{s:5:\"words\";a:0:{}s:9:\"highlight\";a:0:{}s:6:\"common\";a:0:{}s:5:\"users\";a:1:{i:118484;s:5:\"manic\";}s:6:\"forums\";i:0;s:7:\"options\";a:3:{s:11:\"starteronly\";i:0;s:11:\"childforums\";i:1;s:6:\"action\";s:7:\"process\";}}', 'cd78b1a0b7a48890db58b480739e121c');
MySQL Error : Table 'my_forum.search' doesn't exist
Error Number : 1146
Request Date : Wednesday, May 19th 2010 @ 12:15:00 PM
Error Date : Wednesday, May 19th 2010 @ 12:15:01 PM
Script : http://www.mysite.com/forum/post_thanks.php?do=findthanks_user_gave&u=118484
Referrer :
IP Address : 66.249.65.181
Username : Unregistered
Classname : vB_Database
MySQL Version :
|
Quote:
Originally Posted by Golzarion
The same problem .... I think it is a bug for this hack on vB 4.0.3 !
|
This questioned has been asked and answered several times in this thread.
Quote:
Originally Posted by imagirlgeek
What I did to resolve this was to comment out these lines in post_thanks.php...
PHP Code:
$db->query_write("
REPLACE INTO " . TABLE_PREFIX . "search (userid, ipaddress, personal, searchuser, forumchoice, sortby, sortorder, searchtime, showposts, orderedids, dateline, displayterms, searchhash)
VALUES (" . $vbulletin->userinfo['userid'] . ", '" . $db->escape_string(IPADDRESS) . "', 1, '" . $db->escape_string($user['username']) . "', '" . $db->escape_string($forumchoice) . "', 'post.dateline', 'DESC', $searchtime, 1, '" . $db->escape_string(implode(',', $orderedids)) . "', " . TIMENOW . ", '" . $db->escape_string(serialize($display)) . "', '" . $db->escape_string($searchhash) . "')
");
$searchid = $db->insert_id();
$vbulletin->url = 'search.php?' . $vbulletin->session->vars['sessionurl'] . "searchid=$searchid";
eval(print_standard_redirect('search'));
I found this query on lines 278 - 285, 413 - 420, and 527 - 534. I commented out all of them 3 days ago and haven't received this error and also haven't seen any adverse effects.
|
If you don't know how to do those edits, upload the attached corrected post_thanks.php file to the forum root and import the attached corrected product-post_thanks.xml file, making sure you select the "overwrite" option.
To fix the cosmetic (font size) errors, apply the fixes in post_thanks_7_82_improvements.zip, posted earlier in this thread bu attached here for convenience.
|