Foundation 6 Accordion Shortcode Example
- Accordion Section 1 TitleHere’s some section one content. You can add anything you want here!
- Accordion Section 2 TitleHere’s section two’s content. Also, The King in the North!
Use the following shortcode to manually insert a Foundation 6 accordion.
[f6_accordion_panel panel-title="First Accordion Section" active-on-load="true" panel-class="anyCSSclassName2"]First section content goes here[/f6_accordion_panel]
[f6_accordion_panel panel-title="Second Accordion Section" active-on-load="false" panel-class="anyCSSclassName3"]Second section content goes here[/f6_accordion_panel]
[f6_accordion] has one attribute:
accordion-class="anyClassName"– Give this accordion a custom class if you’d like to.
[f6_accordion_panel]has three attributes:
panel-class="anyClassName"– Give this accordion panel a custom class if you’d like to.
panel-title="Accordion Panel Title"– This is the title displayed on the accordion panel title bar.
active-on-load="false"– true or false: True makes the accordion panel open on page load, false makes it closed on page load.
Or add the shortcode with a few clicks of the mouse using Visual Composer. Check out the screenshots below!