Fires after each specific row in the Plugins list table.
Description
The dynamic portion of the hook name, $plugin_file
, refers to the path to the plugin file, relative to the plugins directory.
Parameters
$plugin_file
string- Path to the plugin file relative to the plugins directory.
$plugin_data
array- An array of plugin data. See get_plugin_data() and the 'plugin_row_meta' filter for the list of possible values.
$status
string- Status filter currently applied to the plugin list.
Possible values are:'all'
,'active'
,'inactive'
,'recently_activated'
,'upgrade'
,'mustuse'
,'dropins'
,'search'
,'paused'
,'auto-update-enabled'
,'auto-update-disabled'
.
Source
do_action( "after_plugin_row_{$plugin_file}", $plugin_file, $plugin_data, $status );
This an action on which the update link information is hooked. When a plugin is found to have an updated version, an additional row is added after the plugin entry (on the
plugins.php
admin page), enabling a user to view the update details as well as upgrade.Most users simply upgrade and hope for the best without necessarily looking at the details and this hook is a means to add a warning message on the upgrade link for example, asking a user to view the details in case a major code change may affect their setup.
The parameters passed in the filter are,
$plugin_file
– this is a little redundant as the hook already has the file name in it$plugin_data
– an array of plugin attributes which is useful to set some conditions, see below.$status
– if the plugins page is being filtered (for example to show only theactivated
ones), by default it is set toall
.You could compare your currently installed plugin version to the
$plugin_data['new_version']
to determine if you need to show some warning message or something else.