Have a look at in_category() in the codex. You would either insert this into your theme within the post loop or create a function in functions.php
that’ll insert the image and text you want when a post from that category is displayed on screen.
Here’s a test bit of code I put together that works well in the Twenty Fourteen theme. I put it inside the loop in content.php
as a quick test.
if (in_category(1)) {
the_title();
echo "<p style="font-size:80px">Category 1 Test</p>";
}
Related Posts:
- Block multiple categories from Blog
- Gutenberg editor add a custom category as wrapper for custom blocks
- How can I hide a category from Contributors in the edit/add new post screen?
- WordPress Multiple Category Search
- How to remove categories filter from wordpress admin?
- 404 Error On Category and Tags Pages
- Decreasing the Memory Consumption of a WordPress Site?
- Multiple Domain Names – One WP Install (non-Multisite) – Default Each Domain name to Category Archive
- How can I select a primary category?
- how to use a different domain/subdomain for authors/catagories on single site?
- Deleting default category in wordpress
- Delete a specific category when deleting a user
- How to list child categories in custom category template?
- Trash bin for categories
- How to set up sub-categories for author pages?
- View category in the preview of Theme Customizer
- One WordPress Install, Two Categories. Each Category Gets a Domain
- How to have a static category/author page?
- Create single.php for specific category by category id
- Show posts of one category only with Custom Taxonomy on single.php
- Save metabox checkboxes values to custom content type
- Select category in custom query
- Remove “Parent” Selection When Adding/Editing Categories?
- Order Taxonomy Term by date created
- Apply custom category template to subcategories
- Hide post meta data on a specific category
- Format Brand value in Category view [closed]
- Add custom taxonomy under the category title
- How to show in search results posts with a particular tag in a particular category?
- What is the advantage of using header-catname.php over is_category(‘catname’);?
- Remove ‘rel’ attributes from the_category() output
- If newest post of category is newest post in general, skip first post of category
- Multiple menu items highlighted
- in_category() works in single.php but not in page.php?
- Use a wordpress page to display a certain category
- How to view WordPress’ default category IDs?
- Multiple Category Search
- How do I add a function on a specific post category?
- How to create button to direct to certain category
- How to customize category template?
- Category-slug.php not being used
- How would I go about adding custom header images per category?
- WordPress Genesis not excluding category from blog
- Automatically exclude categories from metabox based on title
- Display posts separated by Category in Author’s page
- How to categorize posts under Category 1 and Category 2 which are separate lists of categories, and display them as separate lists in widgets
- How to organize custom categories for filtering and selecting
- Filtering *out* a taxonomy from the admin post list
- How to rewrite the post URL according to the category?
- Putting a Category of posts under a Page
- How to build a simple nav system of custom post type categories and its posts?
- how to “not” display new posts with a specific category on the main page?
- Display thumbnails for certain category posts
- Keyword search in multiple categories
- Is it possible to remove from default category widget?
- How to customize my category pages
- How to make the ‘delete’ button inactive on some categories?
- Two columns in homepage each with one category
- Functions.php: Exclude Category from “Blog”
- How can I display tags as categories?
- Multiple selection for wordpress widget
- Display content from a specific category using cat ID not working
- Different CSS class by category
- how to nest specific category thumbnails inside different containers
- Wrong category nice name is displayed on archive page
- How can i change what one category displays?
- Remove any product that is featured from regular display loop [WooCommerce]
- Two Sections on Woocommerce Catergory Page [closed]
- How to let the user create a selection of categories via the backend
- Display subcategories in dropdown
- Theme for subcategories
- Hide a category of posts from main blog, and only show in category view
- Use blog as base for tags and categories
- Custom css per category and per single post belong in each category
- Restrict CSS on one page
- How to hide widget from certain category
- custom query for both category and pages using global $wpdb;
- I would like to feature a tip on the homepage
- How to add icon over specific thumb
- Rebuilding a Site: How to Show Several Category Posts in Woo Framework Theme?
- Problem with Custom Post Type Categories
- List post only under the category, exclude child category content
- SQL query to get posts from multiple categories but not in a category
- wp_delete_term or wp_delete_category?
- Select posts that match multiple category names, must match all categories listed
- Custom Portfolio Page
- Last x Posted Categories?
- I need advice on how to structure the categories according to the layout i have
- show only sub categories if available?
- How to add meta description, keywords, custom title to a category template
- separate posts to have (kind of) 2 blogs?
- excude a specidic category from showing in the “relative posts”
- Category post count is not correct
- How to create category filter on a blog like on the site below?
- Blog page with posts from specific categories
- Is it possible to set up blog categories without changing permalink structure
- problem with filter of custom portfolio categories
- Deleted categories still listed until additional page refresh
- Redirect Category pages to blog page with query string
- How can I make a category function as a page?