One of the new features in the upcoming WordPress 2.2 release is an option to “Deactivate All Plugins” with one click. Our standard advice is to deactivate all your plugins before upgrading so that out-of-date plugins won’t break your system mid-upgrade. But in the past, you had to deactivate plugins one at a time. Thus the new “Deactivate All Plugins” button to make this easier.
While testing some things on my development system, I was frustrated that after an upgrade, I still had to reactivate my plugins one by one. So I threw together a “Reactivate All Plugins” feature, which I hope will be implemented for the release of WordPress 2.2.
With this patch, when you use “Deactivate All Plugins”, your current active plugins list is saved. Then later, when you attempt to “Reactivate All Plugins”, it will check each plugin one-by-one. The worst that could happen is if one of your old plugins throws a PHP fatal error, then the reactivation is aborted, and no plugins are reactivated. Simpler errors, like a plugin being deleted from disk between the deactivation and reactivation, are handled more gracefully — the valid plugins will be reactivated, and the missing ones will be reported to you.