Jim Maguire
Jim Maguire

Reputation: 1030

Wordpress admin - add item next to "Activate Edit Delete" list

In the plugins section of the admin screen, each plugin generally has a list of a few things you can do, usually "activate, edit, delete". How can I add an item to this list?

Upvotes: 0

Views: 45

Answers (1)

Omer Farooq
Omer Farooq

Reputation: 4074

In your plugin file just add this code.

// Add settings link on plugin page
function your_plugin_settings_link($links) { 
  $settings_link = '<a href="options-general.php?page=your_plugin.php">Settings</a>'; 
  array_unshift($links, $settings_link); 
  return $links; 
}

$plugin = plugin_basename(__FILE__); 
add_filter("plugin_action_links_$plugin", 'your_plugin_settings_link' );

EDIT: OK so i guess you are administrating the sites, and you want your users to report if something goes wrong with any plugin. Here are some of the options.

  • Use Jquery to add links.
  • Use the above function and add a loop around the add_filter, and then loop through `$all_plugins = get_plugins();

Upvotes: 1

Related Questions