HTTP/2 200
server: nginx
date: Sat, 11 Oct 2025 10:36:23 GMT
content-type: text/html; charset=UTF-8
vary: Accept-Encoding
x-olaf: ⛄
vary: accept, content-type
link:
; rel="https://api.w.org/"
link:
; rel="alternate"; title="JSON"; type="application/json"
link: ; rel=shortlink
x-frame-options: SAMEORIGIN
content-encoding: gzip
alt-svc: h3=":443"; ma=86400
x-nc: MISS ord 1
has_post_parent() – Function | Developer.WordPress.org
has_post_parent( int|WP_Post|null $post = null ): bool
Returns whether the given post has a parent post.
$post
int|WP_Post|nulloptionalPost ID or WP_Post object. Default is global $post. Default:null
bool Whether the post has a parent post.
Version | Description |
---|
5.7.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.