How to Check If A Plugin Is Enabled Through API?

How to find out if a particular plugin is enabled in a sub-blog in a multisite blog?

Related posts

Leave a Reply

2 comments

  1. Ya what Rarst said, for his example you can do something like the following but it returns an array with active plugin name/plugin_filename.php

    get_option(‘active_plugins’);

    You can try using use the global $plugin to get a lot more data.

    global $plugins;
    
    $plugins = array(
                'all' => apply_filters( 'all_plugins', get_plugins() ),
                'search' => array(),
                'active' => array(),
                'inactive' => array(),
                'recently_activated' => array(),
                'upgrade' => array(),
                'mustuse' => array(),
                'dropins' => array()
            );