By default in the theme “Twenty Eleven” of WordPress everywhere (except for search results) full posts are displayed. But I don’t like that, because if I click on a category or tag, I just want to get an overview what posts are assigned to it. If I want to read one completely, I can still click on it.
Therefore I wanted to display only excerpts of posts for following pages:
- Search results (which is the case by default already)
- Homepage of the blog
- Category archive pages
- Tag archive pages
- Date-based archive pages (I don’t use them at all right now)
To accomplish that, you just have to replace the line in the “content.php” theme file
<?php if ( is_search() ) : // Only display Excerpts for Search ?>
with this one:
<?php if ( is_home() || is_tag() || is_category() || is_date() || is_search() ) : ?>
That’s it. Now at least I think it looks better for the user and I’m sure also search engines don’t mind that (keyword: “duplicate content”).
This post is also available in Deutsch.