MyBB Community Forums

Full Version: [TUT/SOLUTION] Oh Man, Locked Out of the ACP by a Plugin
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
edit: Oops. This seems to stop EVERY plugin... I believe the better solution is to define NO_PLUGINS as 1.

Deleting a Plugin, the Database Way
[Image: step_1_lockedout.png]

So now you are somehow or another locked out of the ACP. What do you do now if you can't access the plugins page? This is a very short tutorial for removing a plugin utilizing a database administration tool (AKA: phpmyadmin).

Step 1: Don't cry, scream, kick, or damage your keyboard or mouse. There is no need for this, and it will just cost you money if you break something Wink
Step 2: Get access to phpMyAdmin or similar so that you can access the data inside the database.
Step 3: Enter the database that your forum uses, then open up the tableprefix_adminoptions table (where tableprefix_ is your table prefix).
[Image: step2_lockedout.png]
Note to you people who think you are clever: This is not my full table prefix.
Step 4: Find the row where the title column says "plugins".
[Image: step3_lockedout.png]
Step 5: Click edit to edit the row. Now you will have to search for a plugin, by its filename (at least, I believe it is by filename) before .php. For example, Secure MyBB Admin Key is smak before .php.
Step 6: When you find the name in the text, you will see two occurrences of it after a semicolon. Example: s:4:"smak";s:4:"smak"; .
[Image: step4-1_lockedout.png]
Delete that text, but not the semicolon BEFORE the FIRST occurrence. In this example, s:4:"smak";s:4:"smak";.
[Image: step4-3_lockedout.png]
Then, in this example, the text will look like:
[Image: step4-4_lockedout.png]
Note that the previously mentioned code is gone.
Step 7: Save the row, and reload your ACP login page. It should work if you did it right.
[Image: step_end.png]
Note: If a plugin has its own tables or adds columns, you should delete those if they don't have crucial data, as those tables will want to be re-added on reactivation if you reactivate that plugin.

Although this has never happened to me I thank you and I have bookmarked it just in case.

EDIT: Oh and this is my first post. Smile
(2012-05-23, 04:49 AM)Gibson Wrote: [ -> ]Although this has never happened to me I thank you and I have bookmarked it just in case.

EDIT: Oh and this is my first post. Smile

Welcome to the community! As I mentioned in the post, defining no_plugins in init.php is probably much easier, but this works in a pinch. Although, then you have to fix the duplicate template inserts when you reactivate them.
You could always use a tutorial by Paul (considering example of SMAK) instead of plugin. You would just need to update files when you upgrade your MyBB version. Nonetheless, nice tut.
i have same problem i added smak and now i cant use my admin cp not showing anything