[Theme: tanzaku] random post order in the grid is not working on main page (only on single post)
-
hello all,
my problem is, that the random sort order for the posts is not working on the main page grid, but it works on the single post site-grid. i don’t use any plug-ins and used the following code for the grid items:
<!-- grid items--> <?php /* make a new query for grid items (in single page) */ $new_query_arg = 'paged='.$paged; $args = array( 'orderby' => 'rand', 'numberposts' => 100, ); // use this code if you want filter items by category. /* $arr_catID = array(); foreach( get_the_category() as $cat) $arr_catID[] = $cat->cat_ID; if ( count($arr_catID) ) $new_query_arg .= '&cat=' . join(',', $arr_catID); */ remove_all_filters('posts_orderby'); query_posts($args); ?>
do i have to add the random order also for the query of the single wrapper? if so, please explain me how, because i am not a wordpress-pro.
thx!
- The topic ‘[Theme: tanzaku] random post order in the grid is not working on main page (only on single post)’ is closed to new replies.