When my form is submitted, the form “slides out” and using $.get(), I load another page and slide that in. In between the hiding of the form and the showing of the next page, the div collapses and all my footer stuff briefly ends up where the form was.
Then, when the “next page” finishes loading, the footer goes back to the bottom (under the new page content).
because the size of the form can vary a lot, i’m trying to avoid specifying a height for the DIV.
Is there any way to keep the div from changing?
Code:
$("#MyForm").hide("slide", { direction: "left" }, 250, function () {
$.get("../NewPage.html", function (data) {
$("#NewPagePlaceholder").html(data);
$("#NewPagePlaceholder").show("slide", { direction: "right" }, 250);
});
});
The other options above are likely better, you do have the option of setting the hieght based on the child div but it is hard to know if this is a good idea without seeing any code.
For example (untested):