My index.php file is bent on displaying my posts in some seemingly random order. I have tried changing the query using query_posts. I have tried deactivating all of the plugins. I have tried the baseline theme…all to no avail. I even tried writing a totally separate query like this:
<br /> <?php<br /> $page = (get_query_var('paged')) ? get_query_var('paged') : 1;<br /> $mainQuery = new WP_Query();<br /> $mainQuery->query("showposts=10&orderby=date&order=DESC&paged=$page");</p> <p>?><br /> <?php while ($mainQuery->have_posts()) : $mainQuery->the_post(); //main query was returning randomly ordered posts ?><br />
I’m stuck. Please help.
- The topic ‘unable to alter index.php query’ is closed to new replies.