我们如何在Accordion中使用HTML表?
我有一个代码:
<div id="accordion">
<h3>Section 1</h3>
<div>
<p>DIV 1 CONTENTS</p>
</div>
<h3>Section 2</h3>
<div>
<table>
<tr>
<th>A2</th>
<th>B2</th>
<th>C2</th>
</tr>
</table>
</div>
<h3>Section 3</h3>
<div>
<table>
<tr>
<th>A3</th>
<th>B3</th>
<th>C3</th>
</tr>
</table>
</div>
<h3>Section 4</h3>
<div>
<table>
<tr>
<th>A4</th>
<th>B4</th>
<th>C4</th>
</tr>
</table>
</div>
</div>
Jquery代码(使用1.9.1):
$(function() {
$( "#accordion" ).accordion();
});
但是当它遇到表并且手风琴不起作用时,它的输出会停止......
任何解决方案?