Forums

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

Home Forums JavaScript Jquery ui accordion close by default

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

    html block

    <ul>
            <li><a href="#">accordion heading</a>
              <ul>
                <li>
                    <a href="#">sample1
                        <span></span>
                        <span></span>
                        <span></span>
                    </a>
                </li>
                <li>
                    <a href="#">sample2
                      <span></span>
                      <span></span>
                      <span></span>
                     </a>
                </li>
                <li>
                    <a href="#">sample3 
                     <span></span>
                      <span></span>
                      <span></span>
                    </a>
                </li></p>
    
             </ul>
        </li>
    </ul>
    

    jquery code:

    $(".accBlk").accordion({
            accordion:false,
            speed: 500,
            closedSign: '[+]',
            openedSign: '[-]',
            collapsible: true,
            active: false</p>
    
    });
    

    Setting the collapsible to true and active to false , doesnt close the accordion by default.

    Also how to add images to the closedSign: '[+]' and openedSign: '[-]' so that i can replace the strings'[+]’ and ‘[-]’

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