HTTP/2 200
server: nginx
date: Sat, 19 Jul 2025 18:52:10 GMT
content-type: text/html; charset=UTF-8
vary: Accept-Encoding
x-olaf: ⛄
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 2
generate_postdata() – Function | Developer.WordPress.org
generate_postdata( WP_Post|object|int $post ): array|false
array|false Elements of post, or false on failure.
function generate_postdata( $post ) {
global $wp_query;
if ( ! empty( $wp_query ) && $wp_query instanceof WP_Query ) {
return $wp_query->generate_postdata( $post );
}
return false;
}
View all references View on Trac View on GitHub
Version | Description |
---|
5.2.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.