2 Loops, Only Displaying 1 Loop in Both Loops
You can’t add the pre_get_posts action right before the loop. You HAVE to do it in functions.php. It has to be set before the site actually queries the db to set up the loop which happens before your template file is loaded. What you are doing is looping through the exact same query twice, because … Read more