Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Need to add jquery accordion to navigation, selector issues

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
    Posts
  • #30993

    I’m trying to add a dynamic page accordion and I don’t think I am targeting my selectors correctly. This is my code:


    $(document).ready(function()
    {//hide child page
    $('#content ul.menu ul li').hide();
    //when navigate to a child page show all pages
    $('#content ul.menu li.current-menu-item').parent("ul").show();
    //show page list when toggle
    $('#content ul.menu ul li.active ul').show();
    //show cerrent page's child page
    $('#content ul.menu ul li.current-menu-item ul').show();

    $('#content .menu ul li').click(function() {
    $(this).addClass("active");
    $(this).children('ul').slideToggle("slow");
    });

    });

    and my site: http://www.svadsi.info.

    Thanks in advance for any help!!!

Viewing 1 post (of 1 total)
  • The forum ‘CSS’ is closed to new topics and replies.