Uses
Uses | Description |
---|---|
wp-admin/includes/plugin.php: is_plugin_active() | Determines whether a plugin is active. |
Determines whether the plugin is inactive.
Reverse of is_plugin_active(). Used as a callback.
For more information on this and similar theme functions, check out the Conditional Tags article in the Theme Developer Handbook.
(string) (Required) Path to the plugin file relative to the plugins directory.
(bool) True if inactive. False if active.
In the Admin Area:
<?php $active = is_plugin_inactive( $plugin ); ?>
In the front end, in a theme, etc…
<?php include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); $active = is_plugin_inactive( $plugin ); ?>
File: wp-admin/includes/plugin.php
function is_plugin_inactive( $plugin ) { return ! is_plugin_active( $plugin ); }
Version | Description |
---|---|
3.1.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/is_plugin_inactive