Previous Thread
Next Thread
Print Thread
Hop To
#189563 07/01/2007 7:49 PM
Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
There was a problem with our server this evening, I'm not sure what yet. When it came back I had to repair the tables and posts before the forums would work again. I was then able to post as admin.

I then became a user to see if they could post and I was presented with this message:

Database error only visible to forum administrators

I could then not log back in as admin and am now shown this:

Fatal error: Call to a member function error() on a non-object in /home/vhost/domain.com/html/libs/mysql.inc.php on line 210

Any ideas as to what I can do to fix this please smile

Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
Well, the SQL error is only available to admin's; so you'll need to get the content of the error to see what the problem is; you can do this by either enabling sql logging in the control panel or theres a "tick" in the /libs/mysql.inc.php file to show errors to all users (just search for error i think)


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
Thankyou Gizmo. I cannot get into the control panel now frown

Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
I edited the file and now I get this message:

Fatal error: Class 'sql' not found in /home/vhost/domain.com/html/libs/ubbthreads.inc.php on line 115

Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
Parse error: syntax error, unexpected $end in /home/vhost/domain.com/html/libs/mysql.inc.php on line 40

Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
From admin screen:

Fatal error: Call to a member function error() on a non-object in /home/vhost/domain.com/html/libs/mysql.inc.php on line 210

From users screen:

Script: /home/vhost/domain.com/html/libs/ubbthreads.inc.php
Line#: 2026
SQL Error: Table 'ubbt_CACHED_PERMISSIONS' is marked as crashed and should be repaired
SQL Error #: 1194
Query: delete from ubbt_CACHED_PERMISSIONS where CACHED_TIMESTAMP < '1183295190'

Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
What exactly did you do to mysql.inc.php?

By changing:
$showerror = 0;

to:
$showerror = 1;

it should not throw ANY errors other than the anticipated mysql errors...


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
just changed 0 to 1 smile

It then shows users:

Script: /home/vhost/domain.com/html/libs/ubbthreads.inc.php
Line#: 2026
SQL Error: Table 'ubbt_CACHED_PERMISSIONS' is marked as crashed and should be repaired
SQL Error #: 1194
Query: delete from ubbt_CACHED_PERMISSIONS where CACHED_TIMESTAMP < '1183295190'

Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
Run this query from your admin center in database tools, if you can't access your CP, use PHPMyAdmin (or some other similar MySQL database tool) and run the following command:
Code
REPAIR TABLE `ubbt_CACHED_PERMISSIONS` 


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
Done. Received

threads.ubbt_CACHED_PERMISSIONS repair status OK

but still no joy frown

Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
I believe that data is just temporary, so you could try removing the offending lines:
DELETE FROM `ubbt_CACHED_PERMISSIONS` where `CACHED_TMESTAMP`=1183295190


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
I got this Gizmo:

Error

SQL query:

DELETE FROM `ubbt_CACHED_PERMISSIONS` WHERE `CACHED_TMESTAMP` =1183295190

MySQL said: Documentation
#1054 - Unknown column 'CACHED_TMESTAMP' in 'where clause'

Joined: Jun 2006
Posts: 196
I
enthusiast
enthusiast
I Offline
Joined: Jun 2006
Posts: 196
that's because TIMESTAMP includes an I somewhere between T and M tongue

Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
I may have typed that in manuall vs copy and paste wink...


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
Missed that one myself!

Still doesn't work with the I smile

Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
The hosts have said:

The issue seems to be that the /home/vhost/html/libs/mysql.inc.php file is of zero length - I believe this would contain the relevant sql class that is reporting the error.

Upon checking the following additional files are also zero bytes in size.

./images/moods/default_dark/index.html
./images/moods/default/index.html
./images/forumimages/default/index.html
./images/avatars/default/index.html
./sessions/index.html
./sessions/index.htm
./cache/index.html
./cache/index.htm
./libs/mysql.inc.php
./includes/privacy.php
./includes/header-insert.php
./includes/intro_102.php
./includes/index.html
./includes/boardrules.php
./includes/coppainsert.php
./includes/intro_8.php
./templates/compile/index.html
./styles/index.html

Joined: Nov 2006
Posts: 195
Likes: 1
T
Member
Member
T Offline
Joined: Nov 2006
Posts: 195
Likes: 1
mysql.inc.php has been uploaded and the forums have returned but she's very slow

Joined: Jun 2006
Posts: 196
I
enthusiast
enthusiast
I Offline
Joined: Jun 2006
Posts: 196
The only problem with their answer is that you got sql errors. If mysql.inc.php had been empty, you would have gotten no sql errors, since you would not have even known to talk to the database.

In short, their answer could not have possibly caused the original error.

Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
Agreed with ian.

As for 0 length fiels, all of the index.html files should be 0 length, so you actually only have to worry about:
Originally Posted by ThreadsUser
./libs/mysql.inc.php
./includes/privacy.php
./includes/header-insert.php
./includes/intro_102.php
./includes/boardrules.php
./includes/coppainsert.php
./includes/intro_8.php

And even then, the only stock one that would be required is the mysql.inc.php which as ian said, couldn't have been the original error; possibly when you edited the file and you uploaded it to the server it choked


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!

Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
PHP 8 bug in membermanage.tmpl
by phoenix011235 - 09/08/2026 7:47 PM
Are any of these legitmate?
by Baldeagle - 09/06/2026 1:37 PM
After server reboot
by Morgan - 09/02/2026 8:27 AM
Email Settings
by Outdoorking - 05/13/2026 2:44 AM
Who's Online Now
0 members (), 118 guests, and 136 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Ride safe!
Ride safe!
by Morgan, December 7
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20260527)