Log in

View Full Version : Error in PM Message


Skyline_GT
07-22-2005, 08:41 AM
I don't know why when I am trying to view the pm messages I got the following errors.

Database error in vBulletin 3.0.3:

Invalid SQL: SELECT * FROM thread WHERE 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 1

mysql error number: 1064

Date: Friday 22nd of July 2005 02:39:14 AM
Script: http://www.gamerzplanet.net/forums/private.php?do=showpm&pmid=208744
Referer: http://www.gamerzplanet.net/forums/private.php?


The only two file that I recently edit are showthread.php and fuctions_showthread.php I don't know why it will affect private.php...
anyone have any thoughts??
thanks..

Marco van Herwaarden
07-22-2005, 11:57 AM
Well that query is selecting from the thread table, not the pm table. So a bit strange.

Princeton
07-22-2005, 01:17 PM
check your modifications ... I believe fuctions_showthread.php is 'required' in private.php

Skyline_GT
07-23-2005, 12:18 AM
any wrong with this code?

$iscredits = false;
if(!in_array($forum['forumid'], explode(',', $vboptions['credit_sysapplied'])))
{
$iscredits = true;
}

^ from fuctions_showthread

and


// Begin thread Credits
$iscredits = false;
if(!in_array($forum['forumid'], explode(',', $vboptions['credit_sysapplied'])))
{
$iscredits = true;
}
$creditthread = $DB_site->query_first("SELECT * FROM " . TABLE_PREFIX ."thread WHERE threadid = $thread[threadid]");
$creditvote = ceil($creditthread['creditsvote']/$creditthread['totalcreditsvote']);


^ from showthreads.php

these are the codes that I added to the two files. No other changes..

Marco van Herwaarden
07-23-2005, 05:31 AM
The code itself don't look wrong, it only seems it gets executed on a moment that it should not be.

Skyline_GT
07-23-2005, 06:23 AM
The code itself don't look wrong, it only seems it gets executed on a moment that it should not be.

I don't know where is the problem.. can you give me a hand?