You should use the load()
complete callback to get new document's height, otherwise as load()
is async, you would get height before new content is added to the DOM:
$('.navigation').load('includes/navigation.html', function(){
var docheight = $(document).height();
});