jQuery UI Accordion with custom scrollbar
I am playing around with jQuery UI Accordion and i am trying to use jQuery UI Slider as a custom scrollbar (don't ask me why, i am just messi开发者_如何转开发ng around). I have set the max-height of each accordion to 500px.
I then want to loop over every accordion and check if the height is over 500px. If it is i will put in the slider as a scrollbar. However on load the accordions are closed and their height returns as 0.
$('#scroller').height();
Does anyone know how to get the height on load??
Why don't you put $('#scroller').height();
inside the function that expands the accordian? That way you always get the up-to-date info.
精彩评论