The plugin have a bug if a thread id doesnt' exist, just modify the first line.
;-)
PHP Code:
if ($vbulletin->userinfo['userid'] && $threadinfo[threadid])
{
if ($rating = $db->query_first("
SELECT *
FROM " . TABLE_PREFIX . "threadrate
WHERE userid = " . $vbulletin->userinfo['userid'] . "
AND threadid = $threadinfo[threadid]
"))
{
$rated = true;
}
}
Quote:
Originally Posted by codehack
PHP Code:
Invalid SQL:
SELECT *
FROM threadrate
WHERE userid = 1
AND threadid =;
MySQL Error : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 4
Error Number : 1064
Date : Thursday, December 13th 2007 @ 03:01:01 AM
Script : http://www.xxxx.com/forum/showthread.php?t=1
Referrer :
IP Address :
Username :
Classname : vB_Database
help me!! 
|