Skip to content

WP constants

Set these constants in wp-config.php, before WordPress loads. On multisite they apply to the whole installation; they are separate from per-site App policies.

To stop hardening-rule writes, define the constant below. It also prevents auto-prepend installation and refresh. It does not remove existing .htaccess rules or disable runtime security headers. See .htaccess hardening before changing an existing installation.

define('PS_DISABLE_HTACCESS', true);

Patchstack can install an early firewall loader in the must-use plugin directory. Define PS_DISABLE_MU to prevent creating that loader. It also prevents auto-prepend installation and refresh; it does not remove an existing loader or disable a loader already installed.

define('PS_DISABLE_MU', true);

To stop Patchstack registering its WordPress admin menus and related menu assets, define:

define('PS_DISABLE_MENU', true);

This includes the Network Admin menus. It does not deactivate the plugin, stop the firewall, disconnect the site or revoke remote permissions. Keep a separate way to manage the connection and network settings if you hide these menus.

Use WP filters for PHP callbacks that customize behavior. Unlike the constants above, filters belong in a plugin loaded by WordPress.