How Disable a Broken WordPress Theme or Plugin Using Database
A WordPress broken plugin or theme can cause a website not to load correctly or result in the website showing a blank white page. There are different ways you can fix a broken plugin or broken theme in WordPress.
Warning Before You Get Started: Revisions to your website, such as this process below, are considered major revisions. Please make a backup before you begin.
You are welcome to attempt the most common methods to fix this issue. See the following blogs below such as:
- Activate and Deactivate a Theme or Plugin
- Disable/Delete Themes and Plugins in WordPress
- Troubleshooting: Issues with Theme or Images and Clear Cache
All of these can be done with the account log in link and/or the WordPress dashboard.
Occasionally, a broken theme or plugin will disable the site so badly that it's impossible to log in to fix the problem from the dashboard. If this is the problem, then there are two ways to repair the site manually:
-
- Rename the folder that contains the plugin or theme
- Enable/Disable WordPress plugins using the database
Most popular applications (such as WordPress, Drupal, and Joomla) can detect if a theme or plugin is missing.
- Before You Start — Create A Full Backup
- Rename the Folder Containing the WordPress Plugin or Theme
- Renaming the Folder — WordPress Theme
- Renaming the Folder — WordPress Plugin
- Enable/Disable WordPress Plugins Using the Database
- How to Locate the Database Name
- How to Disable in Database — WordPress Theme
- How to Disable in Database — WordPress Plugin
- Summary
Before You Start — Create A Full Backup
Any modifications such as this are considered major, and you should ensure you have a full backup of your WordPress website, which entails website files and its related databases.
Pro Tip Make A Backup: In addition to making sure all your website components are up to date, such as any scripts, WordPress theme, and plugins you use, keep your website data and files protected in the event of accidents, data loss, injections, and hackers. Make sure you have a daily full backup of your website files and databases, or create a full backup of your website files and databases for easy restoration.
To know more about how to make a backup, check out these guides:
- Getting CodeGuard Set Up for Backups
- How To Backup & Restore WordPress using Jetpack - Backup and Restore
- How To Backup Databases: How to Back up a MySQL Database
- How To Restore Databases using Backup icon feature in cPanel: MySQL Database Restore
- To back up and restore your data using FTP: Intro to FTP and How to Migrate a WordPress Site Files
Rename the Folder Containing the WordPress Plugin or Theme
This section will help you to locate and rename the folder for the WordPress plugin or theme.
Renaming the Folder — WordPress Theme
The easiest way is to rename the offending folder. If it's a problem with a theme, navigate to the correct directory. For WordPress, it's /wp-content/themes/ rename the problem directory and retests the installation.
Here's an example walkthrough of renaming the affected directory.
Renaming the Folder — WordPress Plugin
If the problem is with a plugin, navigate to the correct directory for the plugin and rename the problem folder. For WordPress, it is /wp-content/plugins/
Here's an example walkthrough of renaming the affected directory.
Pro Tip: To isolate the issue, you can do this on each plugin one at a time to see what’s causing the problem.
Enable/Disable WordPress Plugins Using the Database
This will show you how to enable or disable a WordPress plugin or theme using the database. Before you proceed, make sure to locate your Database Name.
How to Locate the Database Name
- Log in to your Bluehost Account Manager.
- Click the Hosting tab from the side navigation menu to the left.
- Click the CPANEL link in the Quick Links section.
- Under the Files section, click File Manager.
- Locate and click the Settings button found on the top right-hand corner.
- Preferences windows will appear. Ensure that the Show Hidden Files (dotfiles) box and WebRoot (public_html or www) are selected in default.
- Next, on your File Manager, locate and choose public_html.
- Find the wp-config.php file and click it.
- Right-click, then select edit, then click the edit button on the pop-up window.
- Please take note of the database name. For example:
How to Disable in Database — WordPress Theme
- Once phpMyAdmin is open with the correct database, find the right table. In most cases, this will be wp_options
- Choose to browse, then edit the template and the stylesheet tables.
- Change the name to twentytwentythree (the current default WordPress theme), and click go.
- Once updated, you can access the back end while making changes to your website.
How to Disable in Database — WordPress Plugin
- In phpMyAdmin, click the affected database name from the side navigation menu to the left.
- Click wp_options, then click > to go to the next page. Here, you can access the active_plugins option.
- Once you locate the active_plugins, click edit.
- Under the active_plugins page, you will see lines of code, like the example below:
a:5:{i:0;s:50:"google-analytics-for-wordpress/googleanalytics.php";i:1;s:19:"jetpack/jetpack.php";i:2;s:47:"mojo-marketplace-wp-plugin/mojo-marketplace.php";i:3;s:37:"optinmonster/optin-monster-wp-api.php";i:4;s:24:"wpforms-lite/wpforms.php";}
Take Note: To enable the plugins, please follow the instructions starting Steps 1-3, then paste the code you saved from your PC. Click Go to save changes.
Summary
To ensure your WordPress broken plugin or theme is fixed, there are different methods you can take to locate the specific issue to resolve the problem. This process involves various things you can try, from disabling/enabling a plugin or theme, renaming the folder containing the plugin or theme, updating the plugin or theme, or reaching out to support the source code creator. When implemented with other techniques, your website goes live and back online. Other great tips as you build or edit your website can be found in this blog: Everything you Need to Know About WordPress SEO: Optimization Tips + Best Practices + Plugins.
If you need further assistance, feel free to contact us via Chat or Phone:
- Chat Support - While on our website, you should see a CHAT bubble in the bottom right-hand corner of the page. Click anywhere on the bubble to begin a chat session.
- Phone Support -
- US: 888-401-4678
- International: +1 801-765-9400
You may also refer to our Knowledge Base articles to help answer common questions and guide you through various setup, configuration, and troubleshooting steps.