Xavier Xavier - 4 months ago 76x
Javascript Question

get right position of Element? jQuery or javascript

I wish to get the right position of an element in jquery, i have tried

, and i have read the API document regarding
which is non existent (i believe).


Is an example i wish to alert the right value for.


You want to find the value of the CSS right property?


In plain Javascript:


But, if you want to find the calculated distance from the right edge of an element to the right edge of another one, then you'll have to do that yourself, combining .position().left and .offsetWidth