Last active
December 17, 2015 22:49
-
-
Save lloc/5685045 to your computer and use it in GitHub Desktop.
WordPress - Add link to plugin_action_links
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
define( 'PLUGIN_BASENAME', plugin_basename( __FILE__ ) ); | |
function my_plugin_action_links( $actions, $plugin_file, $plugin_data, $context ) { | |
if ( PLUGIN_BASENAME == $plugin_file ) | |
$actions[] = '<a href="#">Test: plugin_action_links</a>'; | |
return $actions; | |
} | |
add_filter( 'plugin_action_links', 'my_plugin_action_links', 10, 4 ); | |
add_filter( 'network_admin_plugin_action_links', 'my_plugin_action_links', 10, 4 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment