Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR HTML

How to create collapsable using pure Javascript

<div class="collapsable-container">
    <a href="javascript:void(0);" class="collapsable-toggle" data-onOpenText="Hide First Content" data-onCloseText="Show First Content">Show First Content</a>
    <div id="expand">
        This is some Content
    </div>
 </div>
 
 
 <div class="collapsable-container">
    <a href="javascript:void(0);" class="collapsable-toggle" data-onOpenText="Hide Second Content" data-onCloseText="Show Second Content">Show Second Content</a>
    <div id="expand">
        This is some Content
    </div>
 </div>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #How #create #collapsable #pure #Javascript
ADD COMMENT
Topic
Name
3+3 =