1

我做了一个手风琴,但两个折叠分开工作。我希望有:当我点击一个标题时,打开的标题是关闭的,但是这里打开的没有关闭..我的错在哪里?

<div class="accordions_container">
<div class="accordion" id="accordions_491">
    <div class="accordion-group">
        <div class="accordion-heading"><a class="accordion-toggle" data-toggle="collapse" data-parent="#accordions_491"
            href="#accordion_title_toto491">accordion title toto</a>
        </div>
        <!-- .accordion-heading -->
        <div id="accordion_title_toto491" class="accordion-body collapse in">
            <div class="accordion-inner">Content of the accordion here</div>
            <!-- .accordion-inner -->
        </div>
        <!-- .accordion-body -->
    </div>
    <!-- .accordion-group -->
    <div class="accordion-group">
        <div class="accordion-heading"><a class="accordion-toggle" data-toggle="collapse" data-parent="#accordions_491"
            href="#accordion_titi491">accordion titi</a>
        </div>
        <!-- .accordion-heading -->
        <div id="accordion_titi491" class="accordion-body collapse ">
            <div class="accordion-inner">Content of the accordion here</div>
            <!-- .accordion-inner -->
        </div>
        <!-- .accordion-body -->
    </div>
    <!-- .accordion-group -->
</div>
<!-- .accordion -->

4

1 回答 1

0

The provided markup works as intended on jQuery 1.8.2, BS 2.1.1.

Maybe other scripts are interfering.

于 2012-10-30T11:21:34.470 回答