Last active
August 16, 2022 17:09
-
-
Save kwcjr/96d4b419952fdd7c5b5e3aab1fefe3df to your computer and use it in GitHub Desktop.
Get all WP Posts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Snippet Action: Return Child Site Posts. | |
* Snippet Type: Return info from Child Sites. | |
*/ | |
$posts = get_posts( array( | |
'post_type' => get_post_types(), | |
'post_status' => 'publish', | |
'numberposts' => -1, | |
) ); | |
var_dump( $posts ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment