JQuery UI accordion

Hi there,

I am a developing an application which uses the UI Accordion and I was wondering whether there is a way to influence the minimum height of the accordion content because I am currently getting scrollbars appearing in certain browsers if I exceed a certain amount of content. Can I prevent this either in the JS or alternatively in the UI stylesheet?



You can add a “no autoheight” option when you’re creating the accordion. This will expand the accordion area depending on the content inside of it.

$( ".selector" ).accordion({ autoHeight: false });

If you also want to make sure that the accordion doesn’t push down other content, you could use the “no autoheight” option together with setting a height on the accordion content area:

.ui-accordion .ui-accordion-content {

Hi thanks John I will give it a go,