I’d like to be able to show all the posts from a single category on one page. I’d like to format the returned data so it shows the page title (with permalink) and the date the article was written.
query_posts( array ( 'category_name' => 'The Category Name', 'posts_per_page' => -1 ) );
provided by WordPress.org.
Unfortunatly, this shows the article name, with permalink and the whole article content. I want to hide the article content.
This should do the trick… :)
$cat_posts = get_posts('category=10&numberposts=-1');
foreach($cat_posts as $post) : setup_postdata($post);
" rel="bookmark" title="Permalink to < ?php the_title(); ?>">
< ?php the_title(); ?>
< ?php endforeach; ?>
You must be logged in to reply to this topic.