Jquery Accordion 无法在 IE7 中工作,语法问题?
我构建了一个使用 jquery 手风琴的网站,其中包含一些从外部导航链接控制手风琴的简单功能。我在所有浏览器中测试过它,没有任何问题,但在 IE7 中,手风琴加载完全打开,我不知道为什么。任何帮助将不胜感激。
下面使用 jQuery v1.4.4
是我的代码。
<script>
jQuery().ready(function(){
$('#slide-menu').accordion({
autoHeight: false,
navigation: true,
active: false,
collapsible: true ,
header: ".slide-menuItem",
});
$(".slide-menuItem").click(function(event){
window.location.hash=this.hash;
});
});
</script>
External nav functions that are called from onclick
<script>
function Clicked1(){
$("#slide-menu").accordion('activate' , 0)
}
function Clicked2(){
$("#slide-menu").accordion('activate' , 1)
}
</script>
在页面功能上强制手风琴打开
<script>
$(function() {
$("#slide-menu").accordion('activate' , 1)
});
</script>
HTML 标记
<a class="slide-menuItem" href="#people" name="3">people</a>
<div id="content-area">
CONTENT HERE
</div>
<a class="slide-menuItem" href="#work" name="4">work</a>
<div id="content-area">
CONTENT HERE
</div>
我花了两天时间解决这个问题请帮忙,
谢谢
I built a site that uses using jquery accordion, with some simple functions that control accordion from external navigation links. Ive tested it in all browsers with no problem, but in IE7 the accordion loads completely open and I have no idea why. Any help would be much appreciated.
using jQuery v1.4.4
below is my code.
<script>
jQuery().ready(function(){
$('#slide-menu').accordion({
autoHeight: false,
navigation: true,
active: false,
collapsible: true ,
header: ".slide-menuItem",
});
$(".slide-menuItem").click(function(event){
window.location.hash=this.hash;
});
});
</script>
External nav functions that are called from onclick
<script>
function Clicked1(){
$("#slide-menu").accordion('activate' , 0)
}
function Clicked2(){
$("#slide-menu").accordion('activate' , 1)
}
</script>
On page function to force accordion open
<script>
$(function() {
$("#slide-menu").accordion('activate' , 1)
});
</script>
HTML markup
<a class="slide-menuItem" href="#people" name="3">people</a>
<div id="content-area">
CONTENT HERE
</div>
<a class="slide-menuItem" href="#work" name="4">work</a>
<div id="content-area">
CONTENT HERE
</div>
Ive spent two days tying to solve this please help,
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您有一个额外的
,
:杀死它,这应该可以解决问题
You have an extra
,
:Kill it and that should resolve the issue