Skip to content

Instantly share code, notes, and snippets.

@seoagentur-hamburg
Last active April 5, 2019 15:54
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save seoagentur-hamburg/9208817 to your computer and use it in GitHub Desktop.
Save seoagentur-hamburg/9208817 to your computer and use it in GitHub Desktop.
Ein Plugin aus der WordPress Pluginliste ausblenden.
<?php
function ah_hide_plugin() {
global $wp_list_table;
$hidearr = array('plugin-directory/plugin-file.php'); // plugin-directory/plugin-file.php anpassen
$myplugins = $wp_list_table->items;
foreach ($myplugins as $key => $val) {
if (in_array($key,$hidearr)) {
unset($wp_list_table->items[$key]);
}
}
}
add_action('pre_current_active_plugins', 'ah_hide_plugin');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment