WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )apply_filters( "hook_name", "what_to_filter" ).Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
This hook occurs 2 times in this file.
| Line | Code |
|---|---|
| 379 | $search_plugins = array(); |
| 380 | $active_plugins = array(); |
| 381 | $inactive_plugins = array(); |
| 382 | $recent_plugins = array(); |
| 383 | $recently_activated = get_option('recently_activated', array()); |
| 384 | $upgrade_plugins = array(); |
| 385 | $network_plugins = array(); |
| 386 | $mustuse_plugins = $dropins_plugins = array(); |
| 387 | if ( ! is_multisite() || current_user_can('manage_network_plugins') ) { |
| 388 | if ( apply_filters( 'show_advanced_plugins', true, 'mustuse' ) ) |
| 389 | $mustuse_plugins = get_mu_plugins(); |
| 390 | if ( apply_filters( 'show_advanced_plugins', true, 'dropins' ) ) |
| 391 | $dropins_plugins = get_dropins(); |
| 392 | } |
| 393 | |
| 394 | set_transient( 'plugin_slugs', array_keys($all_plugins), 86400 ); |
| 395 | |
| 396 | // Clean out any plugins which were deactivated over a week ago. |
| 397 | foreach ( $recently_activated as $key => $time ) |
| 398 | if ( $time + (7*24*60*60) < time() ) //1 week |
| 399 | unset($recently_activated[ $key ]); |