query_posts category_name and showposts problem
-
I’m having a bit of trouble getting a query_posts to work.
For some reason, the showposts parameter isn’t working, when I specify the category. For example, if I did just a regular
<?php //The Query query_posts('showposts=9'); if (have_posts()) { while (have_posts()) { ... } } wp_reset_query(); ?>
It works fine, and shows nine posts, but if I do
<?php //The Query query_posts('category_name=The Category Name&showposts=9'); if (have_posts()) { while (have_posts()) { the_post(); cfct_template_file('content', 'third'); } } wp_reset_query(); ?>
All it does is display that category. I’ve also tried using ‘cat=111’, and ‘posts_per_page=9’, but they both just show the entire category. When I exclude categories it works fine though.
Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
- The topic ‘query_posts category_name and showposts problem’ is closed to new replies.