I have this HTML code:
<div id="container">
<div id="feedbackBox"></div>
</div>
The #feedbackBox div doesn't appear in, initially.
The CSS is to centralize the div:
#container {
position: absolute; width: 380px; height: 360px; left: 50%; top:50%; padding: 30px;
margin-left: -220px; margin-top: -210px;
}
But I need to change the height of #feedbackbox via jQuery.
I tested it and it doesn't work:
.expandInfo {
height: 500px;
margin-top: -221px;
}
$("#container").removeClass().addClass('expandInfo');
But it doesn't work! The CSS class doesn't apply, much less has been re-done (the calculation) so that the div remains centralized.
#container, not the div within.