maintain dialog center with dynamic content
- by mcgrailm
I would have a dialog with the following
$("#statusbox").dialog({
autoOpen: false,
bgiframe: true,
modal: true,
width: 'auto',
height:'auto',
title:"Check Order Status",
buttons: {
Find: function() {
get_status();
},
Close: function() {
$(this).dialog('close');
}
}
});
and when the user hits the find button it runs ajax and returns orders to the dialog and it get dynamically re-sized but it only extends the box down. Is there way to make the box extend up and down so that the dialog remains centered ?
also if there was enough content then it could potentially go beyond the bounds of the page so I would think I could use a max height to prevent that but what do I do if they re-size the window ?
thanks for any help