By default, a DIV's height is determined by its contents.
But, I override that and explicitly set a height with jQuery:
$('div#someDiv').height(someNumberOfPixels);
How can I reverse that? I want to remove the height style and to make it go back to it's automatic/natural height?
to remove the height:
$('div#someDiv').css('height', '');
$('div#someDiv').css('height', null);
like John pointed out, set height to auto
:
$('div#someDiv').css('height', 'auto');
(checked with jQuery 1.4)