• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

How to add featured post in category only

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › How to add featured post in category only

This topic is: not resolved

Tagged: featured

  • This topic has 1 reply, 2 voices, and was last updated 11 years, 6 months ago by Brad Dalton.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • May 27, 2014 at 5:51 am #106945
    barnabasnagy
    Member

    I want to set up a featured post for a specific category only. Eg If I have a blog with 2 categories ("Lifestyle" and "Farming"). Then I would want to be able to set up a featured post for Lifestyle and a another different post for Farming. This featured post would be always on top of the category page.

    Any ideas how could I do this?

    May 27, 2014 at 7:21 am #106959
    Brad Dalton
    Participant

    Hook in a new widget before the loop on your category archive conditionally from your functions file and populate it with the Genesis featured posts widget.

    Or you could use WP_Query and hook it in using a variety of methods like a template tag or get_template_part.

    Another option is to hard code it into a category template file.

    Here' an example you can use and change the conditional tag in the code http://wpsites.net/web-design/add-content-before-posts-blog-page-only/

    If you want to hard code this into a template, this is the way to name your file . Template Hierarchy http://codex.wordpress.org/Template_Hierarchy


    Tutorials for StudioPress Themes.

  • Author
    Posts
Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2025 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble