Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

querycompleta

// WP_Query arguments
$args = array(
	'post_type'              => array( 'post' ),
	'post_status'            => array( 'publish' ),
	's'                      => 'spazio',
	'nopaging'               => false,
	'paged'                  => '6',
	'posts_per_page'         => '10',
	'ignore_sticky_posts'    => false,
	'order'                  => 'ASC',
	'orderby'                => 'date',
	'meta_query'             => array(
		'relation' => 'AND',
		array(
			'key'     => '_enddate',
			'value'   => 'now',
			'compare' => '>=',
			'type'    => 'DATE',
		),
	),
);

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