Image

determining width and height

I have serveral elements sized using percentages (in CSS). Is there a standard way using javascript to determine the actual width and height of these elements?

Or do I have to calculate it by backing out of the document tree, testing each parent element's size, padding, etc.?

(cross-posted to Imagewebdesign.)