save_post

save_post

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.4.3

do_action('save_post') is found 3 times:

  • /wp-includes/class-wp-customize-manager.php line 3112
    		/** This action is documented in wp-includes/post.php */
    		do_action( "save_post_{$post->post_type}", $post->ID, $post, true );
    
    		/** This action is documented in wp-includes/post.php */
    		do_action( 'save_post', $post->ID, $post, true );
    
    		/** This action is documented in wp-includes/post.php */
    		do_action( 'wp_insert_post', $post->ID, $post, true );
    
    		wp_after_insert_post( get_post( $post_id ), true, $post );
    
    
  • /wp-includes/post.php line 4760
    	 * @param int     $post_id Post ID.
    	 * @param WP_Post $post    Post object.
    	 * @param bool    $update  Whether this is an existing post being updated.
    	 */
    	do_action( 'save_post', $post_id, $post, $update );
    
    	/**
    	 * Fires once a post has been saved.
    	 *
    	 * @since 2.0.0
    	 *
    
  • /wp-includes/post.php line 4934
    	/** This action is documented in wp-includes/post.php */
    	do_action( "save_post_{$post->post_type}", $post->ID, $post, true );
    
    	/** This action is documented in wp-includes/post.php */
    	do_action( 'save_post', $post->ID, $post, true );
    
    	/** This action is documented in wp-includes/post.php */
    	do_action( 'wp_insert_post', $post->ID, $post, true );
    
    	wp_after_insert_post( $post, true, $post_before );
    }
    

See this hook used in plugins: