wpseek.com
Uma área de pesquisa sobre o WordPress para devs e autores do tema



rest_insert_{$this->post_type} › Hooks de Ações WordPress

Desde4.7.0
Obsoleton/a
do_action( "rest_insert_{$this->post_type}", $post, $request, true )
Parâmetros: (3)
  • (WP_Post) $post Inserted or updated post object.
    Required: Yes
  • (WP_REST_Request) $request Request object.
    Required: Yes
  • (bool) $creating True when creating a post, false when updating.
    Required: Yes
Definido em:
Codex:

Fires after a single post is created or updated via the REST API.

The dynamic portion of the hook name, $this->post_type, refers to the post type slug.

Possible hook names include:

  • rest_insert_post
  • rest_insert_page
  • rest_insert_attachment




Fonte

do_action( "rest_insert_{$this->post_type}", $post, $request, true );