update_links
// WP_Query arguments
$args = array(
'post_type' => array( 'movies' ),
'post_status' => array( 'publish' ),
'tax_query' => array(
array(
'taxonomy' => 'dtquality',
'terms' => 'ts',
'field' => 'slug',
'operator' => 'IN',
'include_children' => true,
),
array(
'taxonomy' => 'dtyear',
'terms' => '2016',
'field' => 'slug',
'operator' => 'IN',
'include_children' => true,
),
),
'meta_query' => array(
'relation' => 'OR',
array(
'key' => 'updating_time',
'value' => 'time() - ( 2* 604800)',
'compare' => '<',
'type' => 'TIME',
),
array(
'key' => 'updating_time',
'compare' => 'NOT EXISTS',
),
),
);
// The Query
$query = new WP_Query( $args );
// The Loop
if ( $query->have_posts() ) {
while ( $query->have_posts() ) {
$query->the_post();
// do something
}
} else {
// no posts found
}
// Restore original Post Data
wp_reset_postdata();