and "Disable Per Page Plugins - Improve WordPress Performance", You can easily disable plugins on some WordPress sites (or all but selected sites).
This is useful for speeding up your website, mainly because many front-end plugins load their JavaScript and CSS content on every page, even if you use them on a single page.
Disable Per Page Plugins - How Does Improving WordPress Performance Work?
You can add deactivation rulespluginactive. For example, for a contact form plugin to be used only on the contact page, just add a rule to disable it on all URIs except the contact page.
Demo: https://codecanyon.net/item/deactivate-plugins-per-page-improve-wordpress-performance/23801359
Deactivation rule option for deactivation plugins per page
1. Deactivation type
- Disable on selected URIs
- Disable all URIs except selected
2. URL. select type
- Page
- Custom
3. Select the page to extract the URI(If the page slug changes, it will automatically update)
4. Custom URI conditions
- URI sama dengan...
- URI is not equal to ...
- O URI contém...
- URI does not contain ...
- URI starts with
- URI does not start with
- URI ends with
- URI does not end with
5. Affected Devices
- All
- Desktop
- Mobile
Plugin group
Create multiple plugin groups to add deactivation rules that affect all plugins.
debug mode
Enable debug mode to see what the URI is and which plugins are active/inactive on the current page in the frontend. This will help you create rules and check existing rules.If you are an admin user, the debug box will appear on the UI.
Does deactivating plugins per page affect the backend?
There is an option (not enabled by default) to make all rules with custom URI selections also affect the backend.Some backend pages will remain untouched to avoid issues such as control activation, deactivation, update andInstall the plugin.
Precautions to disable per-page plugins
A set of plugins that work together
If you have a plugin that requires another plugin to work, you need to add those plugins to a plugin group and add a deactivation rule to that group.Deactivating just one of them may cause errors or deactivate all other plugins.
Do not deactivate plugins required by the theme
Some themes require certain plugins to work properly. If you disable these plugins, you may encounter problems.
Deactivation hook won't run
When the plugin is deactivated via my plugin, the actual deactivation function is not called and the deactivation hook is not run.Instead, to make it work on every page, the plugin is simply removed dynamically from the list of active plugins before the page loads.This means that if the plugin performs certain actions when deactivated, those actions will not run when deactivated via the plugin.Disable plugins per page.
For example, some plugins add code to your ".htaccess" file when activated and remove it when deactivated.In this case, if you use my plugin to add a deactivation rule to stop the plugin on a certain page, ".htaccess" code still exists and works on that page, even though the plugin doesn't work on that page.
Do not use this plugin to hide sensitive data
It is not designed to work safely. It is mainly used for website speed optimization, but can also be used for debugging or troubleshooting plugin compatibility issuesDisable plugins per page.
Back up your website
Deactivating plugins page by page is not a natural thing for WordPress and plugin developersDisable plugins per pageAnd the thread doesn't expect that. It works fine most of the time, but sometimes crashes causing other plugins to be disabled or settings to be changed.Always make a recent backup of your site, and if you can, test your changes in a staging site.
The current test is
These are the highest versions of WordPress and PHP I have tested the plugin with. They are not required, it also works on lower versions.It may also work on later versions, but has not been tested on later versions yet.
- WordPress 5.8
- PHP 8.0.3
Changelog: Deactivate Plugins Per Page – Improve WordPress Performance
v1.14.1 – January, 16 2022 Deactivate Plugins Per Page - Improve WordPress Performance - 3 ADDED: An option to choose the priority of the hook we use to change the active_plugins option. In some cases changing this value will solve a conflict with another plugin (but may also cause a conflict with a different plugin). Deactivate Plugins Per Page - Improve WordPress Performance - 4 REMOVED: The fix of the conflict with BuddyBoss plugin in combination with MemberPress Plus and MemberPress + BuddyPress Integration is removed by default. To enable it change the new option called “Priority” to 0. Deactivate Plugins Per Page - Improve WordPress Performance - 5 UPDATED: Language files. v1.14.0 – January, 15 2022 Deactivate Plugins Per Page - Improve WordPress Performance - 6 ADDED: A new rule action that allows you to copy and paste rules from one plugin or group to another. Deactivate Plugins Per Page - Improve WordPress Performance - 7 ADDED: An option to hide plugins with no rules if they are in at least one group. Deactivate Plugins Per Page - Improve WordPress Performance - 8 FIXED: If there were skipped page rules when importing, the page IDs were not listed after the import. Deactivate Plugins Per Page - Improve WordPress Performance - 9 FIXED: If an ajax request failed to be made due to a server error, it would show loading forever. Now shows an error. Deactivate Plugins Per Page - Improve WordPress Performance - 10 FIXED: The plugin no longer works inside the visual editor screen of Elementor, Divi, and WPBakery Page Builder. Deactivate Plugins Per Page - Improve WordPress Performance - 11 FIXED: A conflict with the BuddyBoss plugin in combination with MemberPress Plus and MemberPress + BuddyPress Integration. Deactivate Plugins Per Page - Improve WordPress Performance - 12 FIXED: A conflict with Tutor LMS Pro in combination with the GeoDirectory plugin. Deactivate Plugins Per Page - Improve WordPress Performance - 13 REMOVED: Support for custom REST-API address when trying to skip affecting it by our rules, was removed due to plugin conflicts. Deactivate Plugins Per Page - Improve WordPress Performance - 14 UPDATED: Language and documentation files. v1.13.3 – 30 November 2021 Deactivate Plugins Per Page - Improve WordPress Performance - 3 FIXED: Conflict with plugins that use the REST API when a rule that deactivates on all except selected URIs is present. Deactivate Plugins Per Page - Improve WordPress Performance - 4 FIXED: In some cases this error would occur: PHP Fatal error: Uncaught Error: Call to undefined function is_plugin_active(). v1.13.2 – 7 September 21 Deactivate Plugins Per Page - Improve WordPress Performance - 3 IMPROVED: Compatibility with the Nitro Pack service. This version adds the “ignorenitro” URI parameter to our option with chosen URI parameters to be ignored by rules with custom URI selection. This way when the Nitro Pack bot visits your site to generate its cache, our deactivation rules will be applied correctly. 1.13.1 – 13 August 2021 Deactivate Plugins Per Page - Improve WordPress Performance - 3 FIXED: Could not create rules on version 1.13.0 unless you had installed a previous plugin version before updating to 1.13.0. v1.13.0 – 20 July 2021 Deactivate Plugins Per Page - Improve WordPress Performance - 3 ADDED: An option to add a note to each rule, so you are reminded what it is for. Deactivate Plugins Per Page - Improve WordPress Performance - 4 IMPROVED: Added the new Update URI plugin header, so if a free plugin with the same name as this one is created in the WordPress repository, it doesn’t update and replace this one. Deactivate Plugins Per Page - Improve WordPress Performance - 5 FIXED: The debug box in the customizer admin page now loads in the correct frame, and shows correct data. Deactivate Plugins Per Page - Improve WordPress Performance - 6 FIXED: On some servers you would get a false error about an unexpected response after performing an action. Deactivate Plugins Per Page - Improve WordPress Performance - 7 FIXED: If the icon of some plugin had changed, it would not load the new image. Now it detects it and gets the new one. Deactivate Plugins Per Page - Improve WordPress Performance - 8 FIXED: The plugin no longer works inside the frame of the legacy widget blocks in WordPress 5.8. Deactivate Plugins Per Page - Improve WordPress Performance - 9 FIXED: The plugin no longer works inside the front-end frame of the customizer. Deactivate Plugins Per Page - Improve WordPress Performance - 10 UPDATED: Language files. 1.12.0 – 2 January 2021 Deactivate Plugins Per Page - Improve WordPress Performance - 3 ADDED: An option to show plugins that have rules before all other plugins in the Active / Inactive Plugins sections. Deactivate Plugins Per Page - Improve WordPress Performance - 4 ADDED: Links to select all and deselect all pages when adding or editing rule, and the same for plugins when adding or editing a group. Also a counter for the number of currently selected. Deactivate Plugins Per Page - Improve WordPress Performance - 5 ADDED: An option to enable Local Mode. In local mode all deactivations affect only your device, which is detected by a cookie. Deactivate Plugins Per Page - Improve WordPress Performance - 6 IMPROVED: Some buttons now have a text description as well (instead of just an icon), so it is more clear what they do. Deactivate Plugins Per Page - Improve WordPress Performance - 7 IMPROVED: The calculated list of active plugins after applying the deactivations is now cached in a global variable for the rest of the request to improve performance. Deactivate Plugins Per Page - Improve WordPress Performance - 8 FIXED: A conflict with some plugins that change the active_plugins option would cause some plugins to be deactivated globally. Deactivate Plugins Per Page - Improve WordPress Performance - 9 FIXED: When editing a rule, if there were pages that are not currently published but are selected, the background green selection color would not be there. Deactivate Plugins Per Page - Improve WordPress Performance - 10 FIXED: If there was only one other plugin active, in the Active Plugins section it would show a message that there are no other plugins active. Deactivate Plugins Per Page - Improve WordPress Performance - 11 UPDATED: Language files. v1.11.0 - 7/27/2020 Deactivate Plugins Per Page - Improve WordPress Performance - 1 ADDED: An option to show the plugin icon image next to its name in the Active Plugins and Inactive Plugins sections. Deactivate Plugins Per Page - Improve WordPress Performance - 2 ADDED: An option to cache the admin menus of plugins deactivated on some back-end pages. Deactivate Plugins Per Page - Improve WordPress Performance - 3 ADDED: In a WordPress Multisite you can import the plugin rules and settings into multiple sites at once. Deactivate Plugins Per Page - Improve WordPress Performance - 4 ADDED: An option to enable the plugin debug mode only on the front-end or only on the back-end. Deactivate Plugins Per Page - Improve WordPress Performance - 5 IMPROVED: New layout for the Settings section. Deactivate Plugins Per Page - Improve WordPress Performance - 6 IMPROVED: Compatibility with plugins that change the back-end dashboard address from wp-admin to something else. Deactivate Plugins Per Page - Improve WordPress Performance - 7 FIXED: The iPad device with a Firefox browser was not detected as a mobile device. Deactivate Plugins Per Page - Improve WordPress Performance - 8 UPDATED: Language files. Deactivate Plugins Per Page - Improve WordPress Performance - 9 TESTED: Compatibility with WordPress 5.4.2.
Contents
- Disable Per Page Plugins - How Does Improving WordPress Performance Work?
- Deactivation rule option for deactivation plugins per page
- Plugin group
- debug mode
- Does deactivating plugins per page affect the backend?
- Precautions to disable per-page plugins
- A set of plugins that work together
- Do not deactivate plugins required by the theme
- Deactivation hook won't run
- Do not use this plugin to hide sensitive data
- Back up your website
- The current test is
- Changelog: Deactivate Plugins Per Page – Improve WordPress Performance