<html>
<head>
<script src="http://code.jquery.com/jquery-1.6.1.min.js"></script>
<script>
function Start(){
var h = $('#test').height();
var w = $('#test').width();
$('#result').append( 'height = ' + h + 'px, width = ' + w + 'px, square = ' + (w*h) + '<br/>');
//outer dimentions - including margin, border and padding
var oh = $('#test').outerHeight();
var ow = $('#test').outerWidth();
$('#result').append( 'outerHeight = ' + oh + 'px, outerWidth = ' + ow + 'px, fullSquare = ' + (ow*oh) );
}
</script>
</head>
<body id="body" onload="Start();">
<div id="test">test</div>
<div id="result"></div>
</body>
</html>