MyBB Community Forums

Full Version: How do I get my admin account back if I accidently delete it?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have a question about Mybb web form but it probably would apply to any webforum php cms.

I created a new forum and I have yet to set it up the way i want to. I went into the admn control panel to remove the bots that have hit the site already.

I got over ambitious. I accidently deleted the admin account -- my own account.

How do I get my admin account back if I accidently delete it?
as it is a fresh forum, assuming that your user id is 1 and administrator user group is 4
you can run below sql queries at your database manager (eg. phpMyAdmin)

UPDATE `mybb_users` SET `usergroup` = '4' WHERE `uid` = '1';
UPDATE `mybb_usergroups` SET `cancp` ='1' WHERE `gid` = '4';

Quote:Also, make sure that ./inc/config.php file consists of below line
$config['super_admins'] = '1';

see this guidance if required --> common SQL queries and how to run them
You would need to create a new account and then set it as a Super Admin account (ie follow .m.'s directions). Smile You cannot recover your account as in "undelete" it, but you can recover it by recreating it.