The is_single
function (used in your excerpt.php file) returns true only when the main query contains one single post. Since you’re calling get_template_part
from an archives page, your query contains more than one post, so is_single
returns false and your excerpt.php file bails. Remove the check for is_single
and you should be good to go.
More about is_single
: http://codex.wordpress.org/Function_Reference/is_single
More about conditional tags: http://codex.wordpress.org/Conditional_Tags
Hope this helps.
Related Posts:
- How to get category and archive title?
- Get rid of WordPress category, tag and author archives?
- Get all categories and posts in those categories
- Category archive by year with permalink support /category/YYYY
- get_categories for custom post type with a specific custom taxonomy attached
- How To Modify The Loop in archives.php To Have 11 Posts Per Page and CSS Styling
- 404 Error On Category and Tags Pages
- Force WordPress to Show Pages Instead of Category
- Combine two taxonomies in a hierarchical tree
- How to get posts from two categories with WP_Query?
- Group WP_Query by category
- Decreasing the Memory Consumption of a WordPress Site?
- What’s the URL for a category archive?
- Exclude categories from search query
- How can I reduce the number of database query calls for this custom homepage?
- WP_Query not looking at child category
- Sort posts by tags in category pages
- Get page content by category or tag
- How to get the category of the post and link it to the archive (of the category)
- How to hide a specific category posts in my monthly archive?
- Optimal way to redirect home page to category archive?
- Display posts links from a category group by year
- Display list of Sub-Categories and the posts they contain, within one main Category
- Excluding posts from a category but only if they’re not in multiple categories
- What could be causing my wp_query pagination to break?
- Custom query with category exclusion and post-meta “whitelist”
- Sort category page with custom field
- How to create tabled index of posts in a certain category
- How would you create a “weekly” archive?
- Exclude most recent posts from specific category in wp_query()
- Sticky Posts Not Sticking to Top of Category Archive
- Root level category, tag, author and archive pages to work
- Display one latest post from multiple categories
- Category Specific Archive
- How to Check if a Child Category is Being Queried
- How to have Multiple Archives Widgets, one archive widget per category (in a different page)?
- Are Custom Taxonomy Templates Possible?
- “Sticky” posts for each category (archive.php)
- I want exclude the particular category in sidebar
- How to filter archives both by category and tag?
- Remove Archive Headline and Archive Intro Text fields on category and tag archive pages in WordPress Admin with Genesis framework
- Display only posts from referred category on date archive page
- How to run WP_Query to retrieve attachments to posts only from a particular category?
- Using widget logic I want to show only a widget on the archive page if there are no posts
- What type of page should i use? static page or category page? and what’s the difference? [closed]
- How to query posts from specific authors and categories using WP_query?
- Creating archive pages for children categories
- How to show in search results posts with a particular tag in a particular category?
- Display “add to cart” button on every listing in product category page?
- Custom WP_Query for current category (in category.php)?
- WordPress categories being called “archives” in google links. How to remove?
- List Posts by Category for a Non-Zero, Non-NULL Custom Field Value?
- conditional for sub category on archive page
- Sorting posts by season
- getting content from main domain to sub-domain using category and WP_Query
- weekly archive for custom category
- Ignoring a category in WP_Query still shows the links in next_post_link()?
- 3 Columns, 3 Categories, One Archive, and Pagination
- List of the years with posts presented
- WordPress subcategories return 404 in custom template
- How to remove category titles?
- Show archives by year from just one category
- Enter a variable in the ‘category_name’ parameter
- Archives for each category on WP Multisite
- How to query post like normal search would do. within search.php page
- Category index featured image
- Archive.php filtered by pre-determined category
- How do I call posts with a certain tag?
- Category being displayed without base parmalink
- How to change category and year archive permalinks/rewrite rules?
- How can I define a custom archive for childs of a specific category?
- Get parrent category name
- Restoring default article pagination on archives – Removing custom limits
- Category archive rewrite rule to include category/subcategory?
- add_rewrite_endpoint returns 404 on archives
- Multiple category archive page
- Custom archive.php: retrieve right post categories?
- wp_dropdown_categories() scripts working erratically on sidebar
- Filtering out child category posts from parent category archive not working
- Yearly Archive for Categories with dropdown
- Multiple Loops on category.php with pagination on last loop
- How to get latest posts from each category in regular order
- Category archives with monthly pagination
- change recent posts based on category
- How to remove specific categories from posts?
- Customize category page for different custom taxonomies
- Set colors depending on category
- Category archive is displaying all posts rather than the specific category
- Display posts from a category
- Custom loop of a single category, cannot order by date. What am I missing?
- Pagination on category.php and tag.php not working
- How to Remove a Title from All Category and Tags Page?
- category__not_in and id values from variable
- Use premade array as categories in wp_query?
- Sorting past events by month
- Sort Category Archive pages and place sticky posts first
- Category archive page redirects to home page
- Display posts on category archive organized into subcategories?
- Is there a standard “Archive” block that shows ALL posts from a specified category?
- Display posts in a random order for a specific category