Gets the names of plugins that require the plugin.
Parameters
$plugin_file
stringrequired- The plugin’s filepath, relative to the plugins directory.
Source
public static function get_dependent_names( $plugin_file ) {
$dependent_names = array();
$plugins = self::get_plugins();
$slug = self::convert_to_slug( $plugin_file );
foreach ( self::get_dependents( $slug ) as $dependent ) {
$dependent_names[ $dependent ] = $plugins[ $dependent ]['Name'];
}
sort( $dependent_names );
return $dependent_names;
}
Changelog
Version | Description |
---|---|
6.5.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.