I want to be able to show all post for a given category using my default category template category.php. The problem is the code I'm using sets the specific category ID. So, whenever I click on CAT2... all the post for CAT1 shows. I want it to just show for CAT2 or CAT3... whichever is clicked.
Code:
$args = array (
'cat' => 1,
'orderby' => rand,
'post_type' => 'post',
'post_status' => 'publish',
'posts_per_page' => 1000
);
$my_query = null;
$my_query = new WP_Query($args);
if( $my_query->have_posts() ) {
while ($my_query->have_posts()) {
$my_query->the_post();
// Some code
}
}