In this new example "itemsList" is "content", and "main" is "container", right?
To vertically center itemsList within main after the contents have
loaded, you can just update the CSS I provided above from your JS
code.
Something like this (jQuery):
$.get('/...', {}, function(data, textStatus) {
... code that fills #itemsList ...
$('#itemsList').css('margin-top', - $('#itemsList')[0].offsetHeight/2 + 'px');
});
The other option is to do the positioning entirely in JS, since you're
loading the content from JS anyway. However, you will then run into
problems if you have a flexible layout and the user resizes the
browser window.
Cheers!
Stefano