i have this snippet for specific category it works perfect
but i want little modification to show posts by Ascending order.
<?php
// The Query
query_posts( array ( 'category_name' => 'A', 'posts_per_page' => -1 ) );
// The Loop
while ( have_posts() ) : the_post(); ?>
<li>
<a href="<?php the_permalink() ?>" title="<?php the_title(); ?>"><?php the_title(); ?></a>
</li>
<?php endwhile;
// Reset Query
wp_reset_query();
?>
Pretty sure query_posts is the worst way to query…
Always use get_posts from what I’m constantly told.
Remove the arguments that you don’t use on the array below.
WP_query method with category id’s:
Or change the query like this, but I don’t know how to add ascending to it:
Add ‘order’=> ‘ASC’ to your query
Just add an argument to the array…
…but don’t use query_posts, see here why. Instead you could do this: