Cross browser issue with offset() jquery function?

The chances are there is something wrong (non-crossbrowser) with your markup. But as alternative you could try using native javascript instead document. GetElementById('anchorid').

OffsetTop Of if you wanted to get the offset on the whole page you could use a function like: function findTotalOffset(obj) { var ol = ot = 0; if (obj. OffsetParent) { do { ol += obj. OffsetLeft; ot += obj.

OffsetTop; }while (obj = obj. OffsetParent); } return {left : ol, top : ot}; }.

The chances are there is something wrong (non-crossbrowser) with your markup. But as alternative you could try using native javascript instead. Document.

GetElementById('anchorid'). OffsetTop Of if you wanted to get the offset on the whole page you could use a function like: function findTotalOffset(obj) { var ol = ot = 0; if (obj. OffsetParent) { do { ol += obj.

OffsetLeft; ot += obj. OffsetTop; }while (obj = obj. OffsetParent); } return {left : ol, top : ot}; }.

Thanks for your help – amateur Dec 2 '10 at 18:21.

I am having an issue with the offset() function in jquery when used cross browsers. As you can see the difference in each returned value. I am not too concerned with the difference between FF & IE8 but I am with IE7 and the others.

Is there another function I could use that would be the same or similar cross browsers or a possible fix for this?

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions