delete_{$meta_type}_meta

delete_{$meta_type}_meta

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action

See hook in core

Displaying hooks found in version: wordpress-6.6.2

do_action('delete_{$meta_type}_meta') is found 2 times:

  • /wp-includes/meta.php line 479
    	 * @param int      $object_id   ID of the object metadata is for.
    	 * @param string   $meta_key    Metadata key.
    	 * @param mixed    $_meta_value Metadata value.
    	 */
    	do_action( "delete_{$meta_type}_meta", $meta_ids, $object_id, $meta_key, $_meta_value );
    
    	// Old-style action.
    	if ( 'post' === $meta_type ) {
    		/**
    		 * Fires immediately before deleting metadata for a post.
    		 *
    
  • /wp-includes/meta.php line 1036
    	if ( $meta ) {
    		$object_id = (int) $meta->{$column};
    
    		/** This action is documented in wp-includes/meta.php */
    		do_action( "delete_{$meta_type}_meta", (array) $meta_id, $object_id, $meta->meta_key, $meta->meta_value );
    
    		// Old-style action.
    		if ( 'post' === $meta_type || 'comment' === $meta_type ) {
    			/**
    			 * Fires immediately before deleting post or comment metadata of a specific type.
    			 *