Definition:
function wp_get_post_parent_id( $post_ID ) {}
Returns the post’s parent’s post_ID
Parameters
- int $post_id
- $post_ID
Return values
returns:false on error
Source code
function wp_get_post_parent_id( $post_ID ) { $post = get_post( $post_ID ); if ( !$post || is_wp_error( $post ) ) return false; return (int) $post->post_parent; }
10771
No comments yet... Be the first to leave a reply!