Filter hook 'hook'

in WP Core File wp-includes/plugin.php at line 87

Description

The plugin API is located in this file, which allows for creating actions and filters and hooking functions, and methods. The functions or methods will then be run when the action or filter is called. The API callback examples reference functions, but can be methods of classes. To hook methods, you'll need to pass an array one of two ways. Any of the syntaxes explained in the PHP documentation for the {@link https://www.php.net/manual/en/language.pseudo-types.php#language.types.callback 'callback'} type are valid. Also see the {@link https://developer.wordpress.org/plugins/ Plugin API} for more information and examples on how to use a lot of these functions. This file should have no external dependencies.

Occurrences

Filename Line Number
wp-includes/plugin.php 87

Usage Examples

Example 1

add_filter( 'hook', 'example_callback'

Example 2

add_filter( 'hook', 'example_callback'

PHP Doc

/**
 * The plugin API is located in this file, which allows for creating actions
 * and filters and hooking functions, and methods. The functions or methods will
 * then be run when the action or filter is called.
 *
 * The API callback examples reference functions, but can be methods of classes.
 * To hook methods, you'll need to pass an array one of two ways.
 *
 * Any of the syntaxes explained in the PHP documentation for the
 * {@link https://www.php.net/manual/en/language.pseudo-types.php#language.types.callback 'callback'}
 * type are valid.
 *
 * Also see the {@link https://developer.wordpress.org/plugins/ Plugin API} for
 * more information and examples on how to use a lot of these functions.
 *
 * This file should have no external dependencies.
 *
 * @package WordPress
 * @subpackage Plugin
 * @since 1.5.0
 */