【发布时间】:2014-09-26 08:26:04
【问题描述】:
我正在尝试对 jquery mobile collapsible-set 的折叠/展开执行操作。我正在运行 jquery.mobile-1.4.4 和 jquery-1.11.0。
我已经在 fiddle 上发布了代码来测试它是否有效,但它没有。此功能适用于旧版本的 jquery mobile 和 jquery。
HTLM:
<div id="football" data-role="collapsible-set">
<div data-role="collapsible" data-collapsed="false">
<h3>Section 1</h3>
<p>I'm the collapsible set content for section 1.</p>
</div>
<div data-role="collapsible">
<h3>Section 2</h3>
<p>I'm the collapsible set content for section 2.</p>
</div>
JS:
$('#football').bind('expand', function () {
alert('Expanded');
}).bind('collapse', function () {
alert('Collapsed');
});
有谁知道实现我想要做的事情的方法吗??
提前致谢!
【问题讨论】:
标签: jquery html jquery-mobile