network_admin_plugin_action_links_{$plugin_file}
Filter HookDescription
Filters the list of action links displayed for a specific plugin in the Network Admin Plugins list table. The dynamic portion of the hook name, `$plugin_file`, refers to the path to the plugin file, relative to the plugins directory.Hook Information
File Location |
wp-admin/includes/class-wp-plugins-list-table.php
View on GitHub
|
Hook Type | Filter |
Line Number | 1036 |
Hook Parameters
Type | Name | Description |
---|---|---|
string[]
|
$actions
|
An array of plugin action links. By default this can include 'activate', 'deactivate', and 'delete'. |
string
|
$plugin_file
|
Path to the plugin file relative to the plugins directory. |
array
|
$plugin_data
|
An array of plugin data. See get_plugin_data() and the {@see 'plugin_row_meta'} filter for the list of possible values. |
string
|
$context
|
The plugin context. By default this can include 'all', 'active', 'inactive', 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. |
Usage Examples
Basic Usage
<?php
// Hook into network_admin_plugin_action_links_{$plugin_file}
add_filter('network_admin_plugin_action_links_{$plugin_file}', 'my_custom_filter', 10, 4);
function my_custom_filter($actions, $plugin_file, $plugin_data, $context) {
// Your custom filtering logic here
return $actions;
}
Source Code Context
wp-admin/includes/class-wp-plugins-list-table.php:1036
- How this hook is used in WordPress core
<?php
1031 * of possible values.
1032 * @param string $context The plugin context. By default this can include 'all',
1033 * 'active', 'inactive', 'recently_activated', 'upgrade',
1034 * 'mustuse', 'dropins', and 'search'.
1035 */
1036 $actions = apply_filters( "network_admin_plugin_action_links_{$plugin_file}", $actions, $plugin_file, $plugin_data, $context );
1037
1038 } else {
1039
1040 /**
1041 * Filters the action links displayed for each plugin in the Plugins list table.
PHP Documentation
<?php
/**
* Filters the list of action links displayed for a specific plugin in the Network Admin Plugins list table.
*
* The dynamic portion of the hook name, `$plugin_file`, refers to the path
* to the plugin file, relative to the plugins directory.
*
* @since 3.1.0
*
* @param string[] $actions An array of plugin action links. By default this can include
* 'activate', 'deactivate', and 'delete'.
* @param string $plugin_file Path to the plugin file relative to the plugins directory.
* @param array $plugin_data An array of plugin data. See get_plugin_data()
* and the {@see 'plugin_row_meta'} filter for the list
* of possible values.
* @param string $context The plugin context. By default this can include 'all',
* 'active', 'inactive', 'recently_activated', 'upgrade',
* 'mustuse', 'dropins', and 'search'.
*/
Quick Info
- Hook Type: Filter
- Parameters: 4
- File: wp-admin/includes/class-wp-plugins-list-table.php
Related Hooks
Related hooks will be displayed here in future updates.