August 6th, 2012, 01:59 PM
Are the computed coordinates different from the styled ones?
I want to absolutely position a <div> box (call it box 2) over another one (box 1) so that it perfectly covers it with the exact same dimensions. I do this when the document loads. Box2 needs to have the same width, height and offset as box1.
However when the browser zoom function is used things move around and the box2 needs to be repositioned and resized so that it covers box1 again.
I have worked out that when resizing box2 I need to get the actual CSS hard coded width and height of box1 if possible, not the computed width and height because if I use the latter box2 will not have the correct dimensions (in zoom mode the computed width and height are not the same as the coded ones).
It seems that the offset (top and left) computed values of box1 (when it is absolutely positioned) are not different from the coded ones when the browser is in zoom mode. Am I correct in saying this? Is there anyone here who has experience with this type of problem who can give me advice on it? Thanks?