Cyber-Drugs
asked on
Finding div position
Hi guys,
I have an div, which is:
position:absolute;
height:125px;
width:100%;
and is located inside a table.
I would like to find out the following information:
style.left;
style.right;
style.bottom;
Now, since those details are not defined in the original stylesheet, javascript returns a NULL value. Any work-arounds for this?
Cheers guys!
I have an div, which is:
position:absolute;
height:125px;
width:100%;
and is located inside a table.
I would like to find out the following information:
style.left;
style.right;
style.bottom;
Now, since those details are not defined in the original stylesheet, javascript returns a NULL value. Any work-arounds for this?
Cheers guys!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Thanks for splitting points!
See you.
See you.
I was just wondering if this library could help you
http://www.javascripttoolbox.com/lib/objectposition/
try the demo and see by yourself
http://www.javascripttoolbox.com/lib/objectposition/
try the demo and see by yourself
ASKER
I did wonder how long until someone commented on that, haha! ;-)
That works perfectly, and I'm happy to calculate, as long as I get the numbers to work with, which you have provided me with!
RozanaZ
Thanks for the link, I did see it when I did a quick search, but since it's title had "position:relative", I didn't even bother to look at it, but I now see it had what I wanted. Thanks for bringing that to my attention.
Splitting the points evenly on this one, yes Zvonko was first to reply, but RozanaZ pointed out something I should of found before asking my question.
Cheers guys (and gals)