[jQuery] jQuery Positioning Off - Help Needed!

[jQuery] jQuery Positioning Off - Help Needed!


I'm in the middle of beta testing a new Intranet for my company. I've
heavily relied on jQuery and various jQuery plugins for this project.
Mostly, it has been a success. There are two issues that have me scratching
my head, though. I'll separate them into two different threads, because
they are unrelated.
The first item is a livesearch that I've built. When a user starts typing,
a box appears just under the input box and shows them the top matches. The
positioning code had been based on Google's Google Suggest code from way
back when they first showed that off. I decided that I needed to jQuery-ize
it and came up with this:
    function JQ_PinElementX(ElementToPinID, PinToObjID) {
        var TopPos, LeftPos;
        
        LeftPos = $("#" + PinToObjID).offset({ border: true, padding: true }).left
+ $("#" + PinToObjID).scrollLeft();
        TopPos = $("#" + PinToObjID).offset({ border: true, padding: true }).top +
$("#" + PinToObjID).scrollTop() + $("#" + PinToObjID).height();
         $("#" + ElementToPinID).css("top", TopPos).css("left", LeftPos);
    }
This should find the Left and Top positions of the "PinTo" object and then
set the ElementToPin object just beneath it. However, what's happening is
that the box is appearing way down the page. In addition, showing the
Explorer bar in IE (e.g. History or Favorites) moves the box over more.
Since the page itself is part of an Intranet, I can't give any public pages
for you to view, but here's a screenshot of the issue (the box contained
user names and titles, so I obscured that): http://twitpic.com/6qza
Thanks for any help you can give me.
-Jason Levine
--
View this message in context: http://www.nabble.com/jQuery-Positioning-Off---Help-Needed%21-tp18856153s27240p18856153.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.