Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // WP_Query arguments
- $args = array(
- 'post_type' => 'trabajo',
- 'posts_per_page' => '2',
- 'paged' => ( get_query_var('paged') ) ? get_query_var('paged') : 1,
- );
- // The Query
- $trabajo_query = new WP_Query( $args );
- $temp_query = $wp_query;
- $wp_query = NULL;
- $wp_query = $trabajo_query;
- // The Loop
- if ( have_posts() ) {
- while ( have_posts() ) {
- the_post();
- the_title();
- }
- }
- wp_reset_postdata();
- the_posts_navigation();
- $wp_query = NULL;
- $wp_query = $temp_query; // Reset
Add Comment
Please, Sign In to add comment