Un motore di ricerca WordPress per sviluppatori e autori di temi



rest_pre_insert_{$this->post_type} ›

Da4.7.0
Deprecaton/a
apply_filters( "rest_pre_insert_{$this->post_type}", $prepared_post, $request )
Parametri: (2)
  • (stdClass) $prepared_post An object representing a single post prepared for inserting or updating the database.
    Richiesto:
  • (WP_REST_Request) $request Request object.
    Richiesto:
Definito a:
Codex:

Filters a post before it is inserted via the REST API.

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





Sorgenti

return apply_filters( "rest_pre_insert_{$this->post_type}", $prepared_post, $request );