• keress

    (@keress)


    I’ve made a child theme off of Twenty Twelve. Something is amiss. The menu-toggle doesn’t work when my child theme is activated, although it works fine if Twenty Twelve is activated. I’ve copied over the js files into my child theme folder. What else can I try? Where is the navigation.js referenced? I’m thinking it needs to be amended so that it’s pointing where it needs to point.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Andrew Mills

    (@andrewmills)

    Any chance we could see a link to the site in question? It’s difficult to diagnose without seeing it.

    Thread Starter keress

    (@keress)

    Sure.

    https://midnightwhistler.com

    I’ve had the same problem before. The last site I did I just got rid of it and did something different. Now I’d like to figure out what the deal is. I’m sure it’s not just me.

    Thanks

    Andrew Mills

    (@andrewmills)

    Thanks for the link.

    Either you’ve already solved the puzzle in the interim . . . or I’m misunderstanding what you mean by menu-toggle (i.e. changing the manner in which the navigation menu is displayed once the screen size drops below a certain threshold, right?)

    FWIW, it’s definitely pulling navigation.js from the TwentyTwelve theme, down in the very bottom of the document (like third line from the bottom).

    Thread Starter keress

    (@keress)

    When I shrink the screen size and click the menu toggle nothing happens. I’m in Firefox. There is a “Pages” widget in the sidebar that looks like a menu, and it’s showing at the bottom of the page. Is that what you’re seeing.

    Andrew Mills

    (@andrewmills)

    Thank you for elaborating. I believe I understand now.

    Let me share what I am seeing, and you can tell me if it helps or not:

    <div class="nav-menu"> // this has display:none;
    <ul class="nav-menu toggled-on"> // this switches between display:none and display: inline-block
    <li class="current_page_item"><a href="https://midnightwhistler.com/" title="Home">Home</a></li>
    // omitting additional menu items, etc.
    </ul>
    </div>

    The same class, nav-menu, is applied to both the div and the ul. The click event on the menu button adds/removes the toggled-on class from the ul, but since the parent div always has display set to none, the inner ul never gets to be seen.

    Sort of like wearing two cloaks of invisibility– even if you turn the inner one off deliberately, the outer one prevents people from seeing you, if that makes sense. Is the outer div necessary?

    Thread Starter keress

    (@keress)

    Okay, then I need to figure out what I did to turn that off. Though I didn’t fool with the display settings, so I’m confused. I’ll have to go figure it out. Thanks.

    Andrew Mills

    (@andrewmills)

    So, the outer div is necessary then?

    I know that this is half a year old… but I have exactly the same issue.

    DId you figure out how to make it work?

    (I’m working with WP 3.6.1 and a twentythirteen-child theme)

    @manugarrido – not the same theme = not the same issue. Please post your own topic rather then posting in multiple old ones.

    Oh sorry. Thought it was a the same problem.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Getting menu toggle to work with child theme’ is closed to new replies.