• Resolved santebarleyreviewhq

    (@santebarleyreviewhq)


    Hi,

    My blog site, i choose the Front page display settings to “YOUR LATEST POSTS”.

    I would like to be available also in this display the page as well. I have a number of pages and i want them to be in this display.

    Thanks,

    Jhuls

Viewing 2 replies - 1 through 2 (of 2 total)
  • function pages_in_home_loop( $query ) { if ( is_home() && $query->is_main_query() )
    $query->set( 'post_type', array( 'post', 'page') ); return $query; }
    add_filter( 'pre_get_posts', 'pages_in_home_loop' );

    Put that in your (ideally) child-theme’s functions.php file

    Thread Starter santebarleyreviewhq

    (@santebarleyreviewhq)

    Wow… it works…

    Thank you so much…

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to display both pages and post in the front page displayes?’ is closed to new replies.