show-notice
hide-notice

Friday 23 August 2013

How to Display/hide sub list items in jQuery


Introduction:

here i will explain How to Display/hide sub list items in jQuery.

Description:

The most useful Jquery post provide in previous article now, today i will provide  How to Display/hide sub list items in jQuery.

HTML:


JS:
$(document).ready(function(){   
    $('ul li.expanded > a')
    .attr('data-active','0')
    .click(function(event){
       $('.submuneu').hide();    
        if($(this).attr('data-active')==0){
            $(this).parent().find('ul').slideToggle('slow');
            $(this).attr('data-active','1');
        }
        else
          $(this).attr('data-active','0');        
    });
        $('a.on').click(function(){
        $('a.on').removeClass("active");
        $(this).addClass("active");
    });

});

SHARE THIS POST   

3 comments :


  1. Testimony On How I Got My Lost Lover Back!!!


    An amazing testimony on a spell caster who brought my wife back to me,my name is Robert Buyback,i live in Maryland/USA,and I'm happily married to a lovely and caring wife,with two kids.A very big problem occurred in my family seven months ago,between me and my wife.so terrible that she took the case to court for a divorce.she said that she never wanted to stay with me again,and that she didn't love me anymore.So she packed out of my house and made me and my children passed through severe pain. I tried all my possible means to get her back,after much begging,but all to no avail.and she confirmed it that she has made her decision,and she never wanted to see me again.So on one evening,as i was coming back from work,i met an old friend of mine who asked of my wife.So i explained every thing to her,so she told me that the only way i can get my wife back,is to visit a spell caster,because it has really worked for her too.So i never believed in spell,but i had no other choice,than to follow her advice. Then she gave me the email address of the spell caster whom she visited.{bravespellcaster@gmail.com}So the next morning,i sent a mail to the address she gave to me,and the spell caster assured me that i will get my wife back the next day.What an amazing statement!! I never believed,so he spoke with me,and told me everything that i need to do. Then the next morning, So surprisingly, my wife who didn't call me for the past seven {3}months,gave me a call to inform me that she was coming back.So Amazing!! So that was how she came back that same day,with lots of love and joy,and she apologized for her mistake,and for the pain she caused me and my children. Then from that day,our relationship was now stronger than how it were before,by the help of a spell caster.So, i will advice you out there to kindly visit this great man called Dr.Brave,if you are in any condition like this,or you have any problem related to "bringing your ex back. So thanks to the bravespellcaster@gmail.com for bringing back my wife,and brought great joy to my family once again. {bravespellcaster@gmail.com} Thanks...

    ReplyDelete
  2. Building a distributed team can be stressfull and challenging. But it gets way easier when you have a detailed checklist of all actions you should take. Check out this article to learn more about how to hire offshore developers

    ReplyDelete
  3. Hello everyone my name is Sophie,i am from Canada I feel very happy to share my great and wonderful testimony with everyone on this platform..: I was married for 4 years to my husband and all of a sudden another woman came into the picture he started hating me and he was abusive and all because i never bear him a child. but i still loved him with all my heart and wanted him at all cost.... He filed for divorce and my whole life was turning apart and i didn't know what to do, he moved out of the house and abandoned me all alone,one day a very close friend of mine told me about trying spiritual means to get my husband back,so i went online to search and i came across so many spell caster who only wasted my time and took a lot of money from me,but i went back to her and told her that spiritual way has only taking my money and not yielding anything, and she introduced me to a spell caster,drgurulovespelltemple@yahoo.com, so i decided to try it. although i didn't believe in all those things because of what i have gone through lately,i contacted the Doctor and explain all my problems to him and he told me that i shouldn't worry that when he cast the spell on me and my husband that my husband is going to run back to me and that within 3weeks am going to get pregnant,so i did the little he ask me to do and behold it all work out,my husband run back to me and right now we have Twins boy and a girl,so all thanks to Dr Guru you're indeed a great spell caster, in case anyone needs help here is his email address; drgurulovespelltemple@yahoo.com His spells is for a better life OR whatsapp him now +2349023365076

    ReplyDelete

Design by Gohilinfotech | www.gohilinfotech.blogspot.com