Summery Summery
Generates post data.
Syntax Syntax
Parameters Parameters
- $post
-
(Required) WP_Post instance or Post ID/object.
Return Return
(array|bool) Elements of post, or false on failure.
Source Source
File: wp-includes/query.php
*/ function generate_postdata( $post ) { global $wp_query; if ( ! empty( $wp_query ) && $wp_query instanceof WP_Query ) { return $wp_query->generate_postdata( $post ); } return false;
Advertisement
Changelog Changelog
Version | Description |
---|---|
5.2.0 | Introduced. |