Jquery accordion height:100%

Craig Jonathan Kristensen picture Craig Jonathan Kristensen · Jan 28, 2012 · Viewed 21.4k times · Source

I'm looking to create an accordion style website with 3 menu item that fill 100% of the window when expanded. I can find a lot of different accordions, but none that work properly with height: 100%

Any ideas?

Here is the general layout:

http://i.imgur.com/GLyTX.jpg

http://i.imgur.com/hOUrO.jpg

Answer

Imran Butt picture Imran Butt · Nov 27, 2012
jQuery( "#accordion" ).accordion({
   collapsible: true,
   heightStyle: "content"
});

It will work and if your are using some combo or widget whose size increases after selection or due to any action the size of the accordion increases than by handling that event you can simply call the following;

jQuery( "#accordion" ).accordion( "resize" );

to adjust your accordion.