globalis / wpg-plugins-autoloader
Force enable/disable plugins with environment config
Installs: 5 550
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 6
Forks: 0
Open Issues: 0
Type:wordpress-muplugin
Requires
- php: >=5.5
This package is auto-updated.
Last update: 2024-10-29 05:04:55 UTC
README
Installation
- Parse below code to your wp-config/< WP_ENV >/options.php file.
// WPG PLUGINS AUTOLADER : FORCE ENABLE $wpg_force_plugins_enable = [ 'redis-cache/redis-cache.php', ]; define('WPG_FORCE_PLUGINS_ENABLE', serialize($wpg_force_plugins_enable)); // WPG PLUGINS AUTOLADER : FORCE DISABLE $wpg_force_plugins_disable = [ 'bwp-minify/bwp-minify.php', ]; define('WPG_FORCE_PLUGINS_DISABLE', serialize($wpg_force_plugins_disable)); // WPG PLUGINS AUTOLADER : FORCE ENABLE NETWORK-WIDE $wpg_force_plugins_enable_multiste = [ 'multisite-clone-duplicator/multisite-clone-duplicator.php', ]; define('WPG_FORCE_PLUGINS_NETWORK_ENABLE', serialize($wpg_force_plugins_enable_multiste)); // WPG PLUGINS AUTOLADER : FORCE DISABLE NETWORK-WIDE $wpg_force_plugins_disable_multiste = [ 'wordpress-mu-domain-mapping/domain_mapping.php', ]; define('WPG_FORCE_PLUGINS_NETWORK_DISABLE', serialize($wpg_force_plugins_disable_multiste));
- Modify $wpg_force_plugins_enable and $wpg_force_plugins_disable as you wish.