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 |
|---|---|
| 252 | * Fires immediately after updating a post's metadata. |
| 253 | * |
| 254 | * @since 2.9.0 |
| 255 | * |
| 256 | * @param int $meta_id ID of updated metadata entry. |
| 257 | * @param int $object_id Object ID. |
| 258 | * @param string $meta_key Meta key. |
| 259 | * @param mixed $meta_value Meta value. |
| 260 | */ |
| 261 | do_action( 'updated_postmeta', $meta_id, $object_id, $meta_key, $meta_value ); |
| 262 | } |
| 263 | |
| 264 | return true; |
| 265 | } |
| 266 | |
| 267 | /** |
| 268 | * Delete metadata for the specified object. |
| 269 | * |
| 270 | * @since 2.9.0 |
| Line | Code |
| 619 | |
| 620 | // Clear the caches. |
| 621 | wp_cache_delete($object_id, $meta_type . '_meta'); |
| 622 | |
| 623 | /** This action is documented in wp-includes/meta.php */ |
| 624 | do_action( "updated_{$meta_type}_meta", $meta_id, $object_id, $meta_key, $_meta_value ); |
| 625 | |
| 626 | if ( 'post' == $meta_type ) { |
| 627 | /** This action is documented in wp-includes/meta.php */ |
| 628 | do_action( 'updated_postmeta', $meta_id, $object_id, $meta_key, $meta_value ); |
| 629 | } |
| 630 | |
| 631 | return true; |
| 632 | } |
| 633 | |
| 634 | // And if the meta was not found. |
| 635 | return false; |
| 636 | } |
| 637 | |