• Hi, I have a problem here, how can I get an specific single post for a “recent news” with offset… I’ve made a mistake here?

    <?php
    // Begin Blog Loop
        $get_news = new WP_Query( 'showposts=2&cat='.get_cat_id( get_option(       'blog_cat' ) ).'&offset=1' );
        while ($get_news->have_posts()) : $get_news->the_post();
    ?>
Viewing 1 replies (of 1 total)
  • Offset determines which post you want to start from, 0 being the first one. If you want to get a specific single post, you would surely want to specifiy the post id?

Viewing 1 replies (of 1 total)
  • The topic ‘Retrieve Blog Post with offset=1’ is closed to new replies.