get_post_ancestors


get_post_ancestors ( $post )

Parameters:
  • (int|WP_Post) $post Post ID or post object.
Returns:
  • (array) Ancestor IDs or empty array if none are found.
Defined at:

Description

Retrieve ancestors of a post.

Related Functions

_get_post_ancestors, get_ancestors, get_post_custom, get_post_class, get_post_custom_keys

Top Google Results

User discussions

wpseek mobile