How to Use Collapse Example in Bootstrap?

By Hardik Savani November 5, 2023 Category : Bootstrap

Sometimes to require collapse for display large text with title.Always we like to use collapse for data content. So if you think how to use collapse in my project then it is very easy you have to just copy bellow example and run in your local you will find result. In this example i provide bootstrap collapse example with code so it pretty simple to use.


<html lang="en">


<title>Bootstrap collapse example</title>

<link href="" rel="stylesheet">

<script src=""></script>

<script src=""></script>



<a class="btn btn-danger" role="button" data-toggle="collapse" href="#collapseExp" aria-expanded="false" aria-controls="collapseExp">

Link with href


<!-- collapse contain -->

<div class="collapse" id="collapseExp">

<div class="well">

<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod

tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,

quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo

consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse

cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non

proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>



<!-- collapse contain end -->