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.
| Line | Code |
|---|---|
| 1508 | case 'custom-header': |
| 1509 | case 'custom-background' : |
| 1510 | // specific custom header and background capabilities can be registered by passing |
| 1511 | // an array to add_theme_support() |
| 1512 | $header_support = $args[0]; |
| 1513 | return ( isset( $_wp_theme_features[$feature][0][$header_support] ) && $_wp_theme_features[$feature][0][$header_support] ); |
| 1514 | break; |
| 1515 | } |
| 1516 | |
| 1517 | return apply_filters('current_theme_supports-' . $feature, true, $args, $_wp_theme_features[$feature]); |
| 1518 | } |
| 1519 | |
| 1520 | /** |
| 1521 | * Checks a theme's support for a given feature before loading the functions which implement it. |
| 1522 | * |
| 1523 | * @since 2.9.0 |
| 1524 | * @param string $feature the feature being checked |
| 1525 | * @param string $include the file containing the functions that implement the feature |
| 1526 | */ |