Skip to content

Instantly share code, notes, and snippets.

@robincornett
robincornett / plugin.php
Created November 10, 2017 18:52
Code snippet to add a custom plugin icon to the WordPress plugins update page. Icons were added to this page in WordPress 4.9 and are automatically shown for plugins hosted in the WordPress repository, but not for plugins hosted/updated elsewhere.
<?php
add_filter( 'all_plugins', 'prefix_add_plugin_icon' );
/**
* Add a custom plugin icon to the plugins update page (introduced in WP4.9).
*
* @param $plugins
*
* @return mixed
*/