Perhaps I do not understand your question, but the offset should give you two variables: horizontal and vertical. This determines the position of the element. So you are looking for:
$("#whatever").offset().left
and
$("#whatever").offset().top
If you need to know where the right border of your element is, you should use:
$("#whatever").offset().left + $("#whatever").outerWidth()
Greg Jun 15 '10 at 6:59 2010-06-15 06:59
source share