Activating the JQuery Accordion

Is there another way to activate an accordion menu besides the

.accordion('activate', indexval); method? In IE7 this changes my header DIV formatting (it smashes it). The accordion is at the base of the page so when it is activated my header disappears. Can anyone offer me some help with this?

Here's what I have.. The the activation is causing top header div to disappear.

var targetOffset = $('.HwContentInformation').offset().top;
                $('#content,#header').animate({ scrollTop: targetOffset }, .5);

                $("#HwReferences").accordion('activate', 0);

Thanks

Nick

I once had a similar problem, by default accordion will use <h3> tags for it's header elements. Your page header probably has an <h3> tag in it that you aren't expecting to be in the accordion.

What you could do, is change the headers in #HwReferences to <h5> and then do something like this:

$("#HwReferences").accordion({'header': 'h5'}).accordion('activate',0)

HTH

我来评几句
登录后评论

已发表评论数()

相关站点

+订阅
热门文章