Click to See Complete Forum and Search --> : Easy drag and drop question


lessdramatic
02-18-2004, 09:43 AM
Ok, I'm trying to have page that allows for moving layers that saves each of their positions so that I can put their positions into a database.

I've looked through the forums and found this example in this thread here.
http://forums.webdeveloper.com/showthread.php?s=&threadid=24500&highlight=drag
..which references the code found here..
http://www21.brinkster.com/sashwin/survey/moving.html

but i'm still at a loss of how to retrieve their positions to be put into hidden textboxes.

I would appreciate if someone could help me figure out how to output the position of a draggable object into a textbox
(2 textboxes actually, 1 for the left, and 1 for the top).

Thanks for your time.

David Harrison
02-18-2004, 11:57 AM
How's this, it also works for elements that are positioned from the right. I made the text boxes visible so that you could see the script in action.

lessdramatic
02-18-2004, 03:12 PM
Wow. Thank you so much. That example is perfect.

David Harrison
02-18-2004, 03:20 PM
Happy to help. :)