using bootstrap accordian

Permalink
Still a little confused as to how Bootstrap is handled in C5 - I know the dashboard and edit mode uses bootstrap and that there is a minified rewritten Bootstrap.js attached to it. I was wondering if any of the transitions that bootstrap has is available with loading another copy of Bootstrap into our themes? I use the accordian in my non-comcrete5 sites.
I know there is expand.collapse etc. in Market Place the ones I tried only handled one expand/collapse at a time so a FAQ with 20 questions and answers would have me load 20 blocks on top of each other to achieve what was fairly simple to add to any list before.

The bootstrap method is as follows

Collapse bootstrap-collapse.js
About

Get base styles and flexible support for collapsible components like accordions and navigation.

* Requires the Transitions plugin to be included.
Example accordion

Using the collapse plugin, we built a simple accordion style widget:
Collapsible Group Item #1
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you probably haven't heard of them accusamus labore sustainable VHS.
Collapsible Group Item #2
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you probably haven't heard of them accusamus labore sustainable VHS.
Collapsible Group Item #3
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you probably haven't heard of them accusamus labore sustainable VHS.
<code>
<div class="accordion" id="accordion2">
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseOne">
Collapsible Group Item #1
</a>
</div>
<div id="collapseOne" class="accordion-body collapse in">
<div class="accordion-inner">
Anim pariatur cliche...
</div>
</div>
</div>
<div class="accordion-group">
<div class="accordion-heading">
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseTwo">
Collapsible Group Item #2
</a>
</div>
<div id="collapseTwo" class="accordion-body collapse">
<div class="accordion-inner">
Anim pariatur cliche...
</div>
</div>
</div>
</div>
...
</code>
You can also use the plugin without the accordion markup. Make a button toggle the expanding and collapsing of another element.
<code>
<button type="button" class="btn btn-danger" data-toggle="collapse" data-target="#demo">
simple collapsible
</button>

<div id="demo" class="collapse in"> … </div>
</code>

INTcommunications
View Replies:
Arequal replied on at Permalink Reply
Arequal
Don't put another copy of Bootstrap. Use the one which Concrete5 gives to you. If you want to use this out of the Dashboard write:

function view() {
$html = Loader::helper('html');
$this->addHeaderItem($html->css('ccm.app.css')); 
}
INTcommunications replied on at Permalink Reply
INTcommunications
Thanks for that - a couple of questions though

In what file do you place that code - in the elements header.php? What version of Bootstrap is the current concrete 5 using?

Jim
Arequal replied on at Permalink Reply
Arequal
In the controller.php.