• bkdimri

    (@bkdimri)


    hello,
    I have a loop in a custom page template. The loop works fine when i use it on the home page. But it doesn’t work when i use it on other page using the same template has home page.
    The loop fetches posts from different category and displays on the page. I am using theme twenty thirteen( latest updated )
    I am trying to do the same as in this
    https://www.wpbeginner.com/wp-themes/how-to-create-a-grid-display-of-post-thumbnails-in-wordpress-themes/

    Here is the code

    <?php
    
    global $query_string;	query_posts($query_string.'posts_per_page=12'.'post_type=post');
    if(have_posts()) :	while(have_posts()) :  the_post();
    ?>

  • The topic ‘Loop not working on custom page’ is closed to new replies.