Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

General Page Query

General Page Query For Pages

// WP_Query arguments
$args = array(
);

// The Query
$queryPage = new WP_Query( $args );

// The Loop
if ( $queryPage->have_posts() ) {
	while ( $queryPage->have_posts() ) {
		$queryPage->the_post();
		// do something
	}
} else {
	// no posts found
}

// Restore original Post Data
wp_reset_postdata();