FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Problem with Mybb :: Changing DB Username





Horizon
I was using an older host when I found this one, and I did have the Mybb forums on my old subdomain. Both hosts uses Cpanel, so that might cure some questions you might have. What I'm having trouble with is the old Cpanel username on the other host was different than this current one. Is there any way to either change the codes in the forums/database to fix this problem (because it can't connect to the database) or a way to change the username at this host? I used a backup of the database from the old forums and added them onto this new host. And i obviously added all the forum files (tyvm, zip files ^^).

I'm not that great with databases, so please be specific.
wumingsden
Horizon wrote:
I was using an older host when I found this one, and I did have the Mybb forums on my old subdomain. Both hosts uses Cpanel, so that might cure some questions you might have. What I'm having trouble with is the old Cpanel username on the other host was different than this current one. Is there any way to either change the codes in the forums/database to fix this problem (because it can't connect to the database) or a way to change the username at this host? I used a backup of the database from the old forums and added them onto this new host. And i obviously added all the forum files (tyvm, zip files ^^).

I'm not that great with databases, so please be specific.


The fact that the cPanel version was different should have no real impact.

1. In your Mybb forums admin centre, disable all plugins (if you have any).

2. Then go to Database Tools -> Backup Database.
On the next page your db tables should appear, on the left tick "Select All", and download the file to your desktop for easy access.

3. Next, download your whole forum folder where the MyBB files are located.

4. Next, create a MyBB mysql db account in your cPanel.

5. Open the config.php file (should be in the inc folder), and edit the following to represent the new database, its pretty much self-explanatory):

Code:
$config['hostname'] = ' ';
$config['username'] = ' ';
$config['password'] = ' ';
$config['database'] = ' ';
$config['table_prefix'] = 'mybb_';


6. Next open the settings.php file, should be located in the same folder, and edit the appropiate settings.

7. Then upload all the files/folders to your FriHost account (via FTP would be the best solution).

8. Upload the mysql database file in phpmyadmin, which will re-create the database.

9. Go to your new forum URL, visit the admin panel and change the board URL, which will change all of the links to the correct ones.


And I think thats it. if you need help or don't understand anything, just ask.
Horizon
Well I had already added the database and the forums, so I decided to go from there, which didn't work xD.

I started from the beginning, and went to change the string in the config.php, and obviously I forgot to edit one thing.. but after I did, visited the forums, and it's now* working perfectly ^^. Tyvm for helping me with this, I would've been forced to re-upload them completely and start from scratch >.<

But there is one more thing. When I logged into the Admin Cpanel, this error came up:

*I made a typo and it said 'not' instead on 'now'.. >.<

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


But it showed up on the bottom of each page in the admin Cpanel, without messing anything up. Nothing else is wrong.. it doesn't show in the regular forum either. Any ideas as to what it means? It doesn't seem 'fatal' as it doesn't mess anything up. :O
------------

Well you can forget the above.. it fixed itself for some reason >.<

Thanks for all your help.
wumingsden
Some scripts like MyBB do create a few errors themself, especially after its moved hosts, but they usually sort themselves out (Y)

I'm glad everything is working properly. As there is no need for this thread to be open, it is now -closed-
if you need it re-opened feel free to PM me
Related topics
Help me with MySQL Account Maintenance and phpBB 2.0.15 :((
Updating phpbb
phpBB transfering
What happend with my name??
SQL and PHP
Hhow many of these can people solve?
What's your Video Card?
MySQL access on server 2
Slow wireless connection but excellent signal
Dreamweaver
membersystem with profile. 80 frih$ to the one who got me 1!
anything@urDomain.com For FREE From Google(For Site Owners)
MyBB 1.2.2 Released
Problem with changing subdomain name<lol>
This topic is locked: you cannot edit posts or make replies.    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.