Having Just Changed Servers
#1
My web host changed my web server last night and now I find through the ACP this error...

Fatal error: Cannot redeclare class databaseEngine in /home/******/public_html/forums/inc/db_mysqli.php on line 13

In the db_mysqli.php file there is...

 9* $Id: db_mysql.php 1370 2006-04-16 13:47:01Z chris $
10 */
11
12 class databaseEngine
13 {
14        /**
15         * The title of this layer.
16         *
17         * @var string

What can I do to correct this?
#2
Anyone?
#3
Try reuploading your ./inc and ./admin directories from a fresh download of MyBB. DO NOT overwrite ./inc/settings.php and ./inc/config.php
[Image: sig.php]
The little boat gently drifted across the pond exactly the way a bowling ball wouldn't.
#4
You also may want to check this topic out as Ryan Ashbrook had the same issue. http://community.mybboard.net/showthread.php?tid=25165
#5
Good point. Have you gone from a PHP5 server to a PHP4 one?
[Image: sig.php]
The little boat gently drifted across the pond exactly the way a bowling ball wouldn't.
#6
Oh cool, Ryan's problem fix did the trick, thanks very much guys. Smile
#7
Actually, this error has made my realise something. Does PHP not have multiple include protection on classes (assuming each class is in it's own file)? I've never seen it used so I guess not.
[Image: sig.php]
The little boat gently drifted across the pond exactly the way a bowling ball wouldn't.
#8
MrDoom Wrote:Actually, this error has made my realise something. Does PHP not have multiple include protection on classes (assuming each class is in it's own file)? I've never seen it used so I guess not.

No it does not. It's a programming error if you call two classes the same thing and include them.

Also this error relates to something completely different than what it should be throwing so I'm almost certain this error is a cause of a PHP bug
#9
The likely problem, is that they haven't installed the mysqli PHP extension on the new server yet.

I had this issue as well.

You need to change the following in config.php:

$config['dbtype'] = 'mysqli';

To:

$config['dbtype'] = 'mysql';

That's just a simple workaround though. I suggest you contact your host and ask them to install the mysqli PHP extension, if the new server can support it.

MySQLi requires MySQL 4.1 or higher.
@ryanashbrook
Do NOT PM me for Support!


Forum Jump:


Users browsing this thread: 1 Guest(s)