• Resolved Davidecs88

    (@davidecs88)


    Hello everyone,
    I have a problem with the main menu: I’ve added two sub-categories to a parent-category in my menu (I made sure to drag the subcategories so as that they are “sub-items” in the menu panel), but after saving the changes and refreshing the page, no sub-category is shown under the parent-category.
    I’m working on a child-theme.
    Anyone knows where I should put my hands on to display the sub-categories?

    Here’s a link to my site

    (the parent-category I’m interested in is “topics”)

    Thanks to anyone who can help me!

Viewing 5 replies - 1 through 5 (of 5 total)
  • I don’t see a menu item called Topics.

    Thread Starter Davidecs88

    (@davidecs88)

    I had to remove it because the category was empty… Any clue about why wouldn’t the menu show the sub-categories? I’ve tried either to place the sub-categories under other existing parent-categories and to delete the parent and to create a new parent from 0, but none worked.
    I’m moving the sub-categories under “Middle East”, so that if you want to inspect the element you can see them there.
    Thanks CrouchingBruin.

    The reason why your sub menu items aren’t showing up is because of this rule in your child theme’s style.css file:

    #access ul li:hover > ul {
       display: relative;
    }

    The value for the display property should not be relative. In fact, relative is not a valid value for the display property, so I’m not sure why it was set to that. The correct value should be block.

    You will also need to change the value for display in this rule from relative to block so your sub menu items are correctly spaced:

    #access a {
       color: #aaa;
       display: relative;
       line-height: 38px;
       padding: 0 10px;
       text-decoration: none;
    }

    I would go through your style.css file and change every instance of display: relative to a correct property value. You can see a list of correct property values for display here.

    Thread Starter Davidecs88

    (@davidecs88)

    Thank you so much CrouchingBruin!
    Honestly, I didn’t know that ‘relative’ was not a valid value for the display property. I can’t remember either why it is set so… Thank you again! I will change those values right away.

    Thread Starter Davidecs88

    (@davidecs88)

    It actually worked CrouchingBruin. Again, thank you so much for your time.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Sub-categories not displayed in menu’ is closed to new replies.