• 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

Conditional Sub menus – controlled by slug / category

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 › General Discussion › Conditional Sub menus – controlled by slug / category

This topic is: not resolved

Tagged: menu

  • This topic has 11 replies, 3 voices, and was last updated 9 years, 7 months ago by kriskl.
Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • December 30, 2012 at 8:56 am #8350
    kriskl
    Participant

    Hi,

    I am using enterprise theme which has 2 Nav menus,

    however, I am struggling to find a way to control the second menu/sub menu
    so it changes automatically depending what is the category/slug

    Because I am trying to migrate old site to Genesis.. manually selecting sub menu for each post/page seems like a lot of pain with almost 2,000 posts/pages..

    i have found some plugins to control widgets based on category, but no luck with conditional menus..

    genesis-subpages-as-secondary-menu ย plugin - is no good, does not work on posts, only pages

     

    any help would be really appreciated, I can't imagine I am the only one trying to achieve this ๐Ÿ™‚

    kris

    January 13, 2013 at 10:00 pm #11742
    ATUB
    Participant

    Take a look at Genesis Simple Menus Plugin -ย http://www.studiopress.com/plugins/simple-menus

    It says you can change the secondary nav menu by category.


    Another Turn Used Books

    August 17, 2013 at 4:09 pm #57091
    kriskl
    Participant

    It took me a while to get back to this issue,

    Yes, I am using Genesis Simple Menus plugin, but it does not allow me to set automatically secondary menu based on the slug,
    I have to change it manually.. for 2,000 or so posts ๐Ÿ™
    that;s why I wondered if there is a way to make it pick the correct secondary menu based on the slug that is used

    August 17, 2013 at 5:39 pm #57102
    Brad Dalton
    Participant

    So you want to display the sub nav for posts in specific categories or on category archive pages?


    Tutorials for StudioPress Themes.

    August 18, 2013 at 1:28 am #57127
    kriskl
    Participant

    I would like to show sub menu for all pages and posts
    each post belongs only to one category

    August 18, 2013 at 5:39 am #57131
    Brad Dalton
    Participant

    In what position? Before or after header?

    Can you link to your site please.


    Tutorials for StudioPress Themes.

    August 18, 2013 at 8:57 am #57146
    kriskl
    Participant

    here is one page (blue is secondary menu)
    http://opentuition.com/acca/

    and here is another
    http://opentuition.com/aat/aatunit30/process_sales_and_receipts/
    these are strictly "wordpress pages", (but later on, for the acca as one category there are many posts belong only to it

    while aat is another category.

    so, this post - should display proper aat menu, not default secondary menu
    etc.

    I hope that makes sense?

    August 18, 2013 at 9:42 am #57155
    Brad Dalton
    Participant

    What you can do is remove either the primary or secondary menu conditionally.

    How many menus do you want to display on pages and posts?


    Tutorials for StudioPress Themes.

    August 18, 2013 at 10:17 am #57160
    kriskl
    Participant

    uhm, not sure I understand,
    both primary and secondary menu are always visible,
    Only the content of the secondary changes (or rather, a different menu becomes the secondary menu) based on what category the post belongs to (or the slug of the post),

    August 18, 2013 at 10:22 am #57162
    Brad Dalton
    Participant

    Have you tried the Genesis Simple Menu's plugin?

    Otherwise you will need custom code with conditional tags.

    I'm assuming you want to display a different sub nav depending on which category your posts are assigned to.

    How many menus have your created?

    Still not clear on exactly what you want.


    Tutorials for StudioPress Themes.

    August 18, 2013 at 10:36 am #57168
    kriskl
    Participant

    sorry, it;s my bad english ๐Ÿ™‚

    here is the post link
    http://opentuition.com/acca/f3/depreciation-example-5/

    (it has 'acca' in the slug, it belongs to 'acca' category.
    and yet, the submenu - is the default secondary menu,
    not the menu I have created specially for this category 'acca'
    using simple menu plugin. I can set the secondary menu to 'acca' but it has to be done manually for every post.
    so, that's sucks ๐Ÿ™‚
    I want to find a way to make it automatically..

    the the description, Genesis simple sidebars might work (if I could replace secondary menu with the widget area..
    I will try this plugin and see if it works the way I expect.

    thank you for your time.

    August 22, 2013 at 9:18 am #58210
    kriskl
    Participant

    Alright, I think the solution to my 'problem' is to create a custom category templates with Genesis

    does anyone know of good tutorials?

    thanks
    kris

  • Author
    Posts
Viewing 12 posts - 1 through 12 (of 12 total)
  • The forum ‘General Discussion’ 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

© 2023 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