The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
database error....for a hack... Details »» | ||||||||||||||||||||||||||
Okay, not sure how to describe this...nor how to fix it. :banana:
I have several special hacks on my board that were installed by various helpers from here and vb.com. This particular hack has been no problem for any upgrade. With this upgrade there is apparently something that messing up in the script. We have special usergroups. While the registered users are "regular members" these special usergroups (we call jewels) are levels of donors. Crown Jewels Rubies Diamonds Each of these groups get special privileges. Avatars for one. All of their group specialites seem to be working. However here is where the glitch comes in: We have a hack that is a page the displays these crown jewels. It is a hack that KIER wrote for displaying mod groups back before this function was added to the VB) CLick on this link and it takes you to a page that is based on templates, a crown.php file ..... I have the link to view these JEWELS in every header of the VB and on my content pages. However since the upgrade last week, whenever anyone clicks on the link, we are getting an error: Quote:
http://www.hystersisters.com/vb2/crown.php in all the headers (I didn't accidently put vb2 in their twice.) while the error shows /vb2/vb2/ Remembering I'm PHP-challenged, is there someplace I can check to find this error? I'm attaching the crown.php file for you to see: Code:
<? // install show admin groups version 2.0 // by Kier Darby: kier@ap3d.com $supermod_usergroup = 51; $admin_usergroup = 50; $mentor_usergroup = 34; // set the next line to "no" if you don't want to show avatars. $showavatars = "no"; $templatesused="postbit_online,postbit_offline,showmoderators,showmods_adminbit,postbit_sendpm,showmods_bit,showmods_forumbit,showmods_forumsplit,postbit_avatar"; require ("./global.php"); function douserinfo() { global $user, $sendpmlink, $onlinestatus, $showonline, $cookietimeout, $showavatars, $avatarenabled; $datecut = time() - $cookietimeout; if ($user[field2] == "") $user[location] = " "; else $user[location] = $user[field2]; if ($user[receivepm] == 0) $sendpmlink = " "; else { $post[userid] = $user[userid]; eval("\$sendpmlink = \"".gettemplate("postbit_sendpm")."\";"); } if ($showonline) if ($user[sessionuserid]>0 && $user[lastactivity]>$datecut) eval("\$onlinestatus = \"".gettemplate("postbit_online")."\";"); else eval("\$onlinestatus = \"".gettemplate("postbit_offline")."\";"); else $onlinestatus = " "; if ($showavatars == "yes") { if ($user[avatarid]!=0) { $avatarurl=$user[avatarpath]; } else { if ($user[hascustomavatar] and $avatarenabled) { $avatarurl="avatar.php?s=$session[sessionhash]&userid=$user[userid]"; } else { $avatarurl=""; } } if ($avatarurl=="") { $user[avatar]=""; } else { eval("\$user[avatar] = \"".gettemplate("postbit_avatar")."\";"); } } } // get administrators & super moderators ********************************************************** $users = $DB_site->query(" SELECT DISTINCT user.*, userfield.*, session.userid AS sessionuserid, session.lastactivity ".iif($avatarenabled,",avatar.avatarpath,NOT ISNULL(customavatar.avatardata) AS hascustomavatar","")." FROM user LEFT JOIN usergroup ON (usergroup.usergroupid = user.usergroupid) LEFT JOIN userfield ON (userfield.userid = user.userid) LEFT JOIN session ON (session.userid = user.userid AND session.userid <> 0 AND user.invisible = 0 AND session.lastactivity>0) ".iif ($avatarenabled,"LEFT JOIN avatar ON avatar.avatarid=user.avatarid LEFT JOIN customavatar ON customavatar.userid=user.userid","")." WHERE user.usergroupid IN($admin_usergroup,$supermod_usergroup,$mentor_usergroup) GROUP BY user.username ORDER BY user.userid "); while ($user = $DB_site->fetch_array($users)) { if ($user[usergroupid] == $admin_usergroup) { if (($admincount++ % 2) == 0) $backcolor = "#DFDFDF"; else $backcolor = "#F1F1F1"; douserinfo(); eval("\$adminbits .= \"".gettemplate("showmods_adminbit")."\";"); } elseif ($user[usergroupid] == $supermod_usergroup) { if (($smodcount++ % 2) == 0) $backcolor = "#DFDFDF"; else $backcolor = "#F1F1F1"; douserinfo(); eval("\$supermodbits .= \"".gettemplate("showmods_adminbit")."\";"); } else { if (($mentorcount++ % 2) == 0) $backcolor = "#DFDFDF"; else $backcolor = "#F1F1F1"; douserinfo(); eval("\$mentorbits .= \"".gettemplate("showmods_adminbit")."\";"); } } // get moderators ********************************************************** $users = $DB_site->query(" SELECT DISTINCT user.*, userfield.*, forum.forumid, forum.title AS forumtitle, session.userid AS sessionuserid ".iif($avatarenabled,",avatar.avatarpath,NOT ISNULL(customavatar.avatardata) AS hascustomavatar","")." FROM moderator LEFT JOIN user ON (user.userid = moderator.userid) LEFT JOIN forum ON (forum.forumid = moderator.forumid) LEFT JOIN userfield ON (userfield.userid = user.userid) LEFT JOIN session ON (session.userid = user.userid AND session.userid <> 0 AND user.invisible = 0 AND session.lastactivity>0) ".iif ($avatarenabled,"LEFT JOIN avatar ON avatar.avatarid=user.avatarid LEFT JOIN customavatar ON customavatar.userid=user.userid","")." ORDER BY user.username ASC, forum.displayorder ASC "); while ($user = $DB_site->fetch_array($users)) { $moderator[$user[userid]] = $user; if ($modforums[$user[userid]] == "") eval("\$modforums[".$user[userid]."] .= \"".gettemplate("showmods_forumbit")."\";"); else { eval("\$modforums[".$user[userid]."] .= \"".gettemplate("showmods_forumsplit")."\";"); eval("\$modforums[".$user[userid]."] .= \"".gettemplate("showmods_forumbit")."\";"); } } unset($user); while(list(, $user) = each($moderator)) { if (($modcount++ % 2) == 0) $backcolor = "#DFDFDF"; else $backcolor = "#F1F1F1"; $forumbits = $modforums[$user[userid]]; douserinfo(); eval("\$moderatorbits .= \"".gettemplate("showmods_bit")."\";"); } // ******************************************************* makeforumjump(); eval("dooutput(\"".gettemplate("showmoderators")."\");"); ?> :ermm: Show Your Support
|
Comments |
#2
|
||||
|
||||
Another error:
Quote:
Any idea why the path is adding an extra vb2/ to the path?? |
#3
|
||||
|
||||
Check in the Admin CP that $bburl (the boards url) is set correctly and that you don't have the directory name twice there.
|
#4
|
||||
|
||||
I checked and I don't. All other functions are fine. Replies and threads, forums and so on....
I'm putting in a ticket at VB.com I guess.... |
#5
|
||||
|
||||
The repeating forum directory is just a by-product of the SQL error - ignore that.
The problem is the query - I had a similar problem in my admin user.php and mod user.php - it is to with the query looking for non-custom avatars. For the life of me I cannot remember what I did to fix it... It's to do with newer versions of vB not liking certain older queries. That doesn't explain your private.php error though, unless you didn't update it completely. When I have time I will look it up for you. |
#6
|
||||
|
||||
Thanks guys. Just an update...I found the culprit. Not VB at all....but a too full server. /usr was so full it couldn't handle even writing correct error logs (thus the error=0 in the error message)
My server holds 16 gig and yet we had it at capacity with the vb of ours. Its not the first time a full server did funky things to the processes of the vb...and each time I forget about this kind of behavior. (Each time its a bit different in its symptoms) We recently upgraded and had additional backups of the database...somewhere between 1-2 gig in size. So...we deleted two backups and *poof* we are in business again and my hacks are all functional again and the other postings.php and private2.php are now working fine. Thanks sooo much for ya'lls help. (And thanks to Logician who found my server tooooo full as the answer) Any idea if adding a hard drive to my server would help with storage space on a rapidly growing database? :-) (I even prune inactive members monthly.) |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|