Click here to Skip to main content
15,915,172 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all ,

Is it possible to get the x and y of an html element ? i tried doing that with top and left but it is not working.And what i was doing is placing an element under another one directly.So i wrote :

JavaScript
e1.left=e.left;
e1.top=e.top+100;


in javascript code.But the placement is not ok.

So how to fix that ?

Thanks in advance.
Posted

1 solution

 
Share this answer
 
Comments
Espen Harlinn 30-Jul-11 12:36pm    
Nice link, my 5
Manas Bhardwaj 30-Jul-11 12:39pm    
thanks Espen!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900