PDA

View Full Version : My VBulletin is screwy! Help!


NinjaBen
01-29-2004, 02:42 PM
Hello i installed VBulletin 2.3.2 on to my server which is detailed as an:

Apache/1.3.29 (Unix) mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 PHP/4.3.3 FrontPage/5.0.2.2634 mod_ssl/2.8.16 OpenSSL/0.9.7a

We us CPanel for our server and we run MySQL version 4.0.15-standard.

I have installed multiple hacks from here including: Store 3.0 by lesane, Physical Iten Add on by Churchmedia, Stats by Afterburner, and Stats by Bane.

The problem is relatively new. The probelm is that SOME member's names do not show up in our second forum "Junk in the Trunk" Their Username does not show up on the "Thread Starter" column or the "Last Post" column (both with in the Forum and on the main page showing both forums). The odd part is that only a 2 member's names have not shown up so far, but some still do.

The problem can be found here:
http://board.weekendninja.com/forumdisplay.php?s=&forumid=3

Thank you in advance for your help!

corsacrazy
01-29-2004, 02:57 PM
so u uprgaded ? that means re installing hacks mate

NinjaBen
01-29-2004, 02:59 PM
No I didn't upgrade at all and all the hacks work fine. And to the best of MY knowledge the hacks never touched the forum that is all screwy. . .

NinjaBen
01-29-2004, 03:04 PM
Oh, and I installed the quick reply hack.

Lesane
01-29-2004, 04:11 PM
Weird problem, let's first check if the name of the author is stored in the table, execute the following query and post the result here:


select postusername,postuserid,threadid from thread where threadid='146'

NinjaBen
01-29-2004, 04:19 PM
I attatched an image of what the results were. . . I wasn't sure what you needed.

Lesane
01-29-2004, 04:27 PM
It shows us that the username of the author is not stored in the table, so there is maybe something wrong in the file newthread.php, let's check that, open newthread.php and find:

Around line 131, your code can be different but post a block code that looks like this:


if ($userinfo=$DB_site->query_first("
SELECT user.*,userfield.*
FROM user,userfield
WHERE (username='".addslashes(htmlspecialchars($username))."' OR
username='".addslashes(eregi_replace("[^A-Za-z0-9]","",$username))."') AND
user.userid=userfield.userid")) {
if (!$password) {
eval("standarderror(\"".gettemplate("error_usernametaken")."\");");
} elseif (md5($password)!=$userinfo['password']) {
eval("standarderror(\"".gettemplate("error_wrongpassword")."\");");
} else {
$bbuserinfo = $userinfo;
$postusername = $bbuserinfo['username'];

if ($user['cookieuser']==1) {
vbsetcookie("bbuserid",$user['userid']);
vbsetcookie("bbpassword",$user['password']);
}
$DB_site->query("UPDATE session SET userid='$bbuserinfo[userid]' WHERE sessionhash='".addslashes($session['dbsessionhash'])."'");
}
} else {
$postusername = htmlspecialchars($username);
}
} else {
$postusername = $bbuserinfo['username'];
}


Let us know how your block looks like.

Then, find:


//create new thread
if ($postpoll) {
$visible = 0;
}


There is a query code under that, something like this:

$DB_site->query("INSERT INTO thread (threadid,title,lastpost,forumid,open,replycount,p ostusername,postuserid,lastposter,dateline,iconid, visible,attach) VALUES (NULL,'".addslashes(htmlspecialchars($subject))."','".time()."','$forumid','1','0','".addslashes($postusername)."','$bbuserinfo[userid]','".addslashes($postusername)."','".time()."','$iconid','$visible','$attachcount')");


Let us know wich line you have.

NinjaBen
01-29-2004, 04:38 PM
Well, i have all three of those blocks, all of them are the same as the ones you posted.

NinjaBen
01-29-2004, 04:43 PM
Just below the last bit I have this, does that matter? $threadid=$DB_site->insert_id();

Lesane
01-29-2004, 04:53 PM
hmm, can you give me the result of this query?


select username from post where threadid='146'


And no, that doesn't matter.. the code belongs there.

NinjaBen
01-29-2004, 04:59 PM
Here are what I have added to newthread.php

From the stats hack by afterburner, this shows up just below the line I mention above:
// Afterburner
$curtime = time();
$date_today = getdate($curtime);
$time_today=mktime(0,0,0,$date_today[mon],$date_today[mday],$date_today[year]);
$res1 = $DB_site->query("UPDATE afterburner_stat SET newthreads = newthreads+1 WHERE time = '$time_today'");
$res2 = $DB_site->query("UPDATE afterburner_stat SET newposts = newposts+1 WHERE time = '$time_today'");
// Afterburner

and I added the stuff from your store hack to newthread.php

Other then that, I haven't made any chnages

NinjaBen
01-29-2004, 05:01 PM
Here ya go!

Lesane
01-29-2004, 05:45 PM
Are those hacks installed after 27 january? Let 'Yo Adrian' post a newthread in 'The Sparring Room' and check if it will be succesfull or not.

NinjaBen
01-29-2004, 06:15 PM
no they were all installed before. . .except the stats and physical product add ons.

and adrian posted again and it showed up fine. . .

NinjaBen
01-29-2004, 06:17 PM
AH HA! It happens when you try to preview the post! It just posts it in the forum without the names. . . now what do you suppose would cause that?

Lesane
01-29-2004, 06:27 PM
I have no idea, i can give a look on your newthread.php file but if that's ok then i am out of ideas.

assassingod
01-29-2004, 06:36 PM
I have no idea, i can give a look on your newthread.php file but if that's ok then i am out of ideas.
Just to note, you aren't allowed to post full vB files.:)

NinjaBen
01-29-2004, 08:18 PM
Ok so I will ask my question again, in light of the new findings.

When a user is submitting a new thread and they click "Preview Thread" it submits the thread and the submitted thread does not show a username under the columns "Thread Starter" and "Last post by"

Edit: What did I just say? - assassingod

NinjaBen
01-29-2004, 08:20 PM
Sorry about that, i didn't see your post :)

Hey Lesane, would you like me to e-mail you the file?

or can you tell me what part you would like to see?

NinjaBen
01-30-2004, 01:52 PM
Is there anyone out there that will still help me with this problem?

Lesane
01-30-2004, 02:27 PM
Have some patience! :)

Upload the file and then pm me with the url.

NinjaBen
01-30-2004, 02:34 PM
Thank Lesane :) I don't mean to be impatient :)