1) graham01Group: Members Posts: 8Joined: 21 Feb 2008Location: englandIP: 90.202.--.--
Posted:
Hello, is it possible to save the co-ordinates of the dragable items into a database?
I only really need 2 textbox's which display the vertical position of the top and bottom of the divs, and I can do the rest from that.
Thanks, Graham.
2) Angus TurnbullGroup: Moderators Posts: 4235Joined: 7 Dec 2003Location: New ZealandIP: 203.109.--.--
Posted:
It surely is. You will just have to do it yourself :). I would suggest building a small JavaScript that upon some "save" event checks the element positions and saves them AJAX style or however to a CGI script on your server. Should not be too difficult if you are familiar with the tech involved! You won't really have to make any modifications to this script.
The only real thing you might want to bear in mind is that the script exposes an "ondragend" event that is called when you release an element, that could come in handy if you want to save positions on the fly.
- Angus.
3) graham01Group: Members Posts: 8Joined: 21 Feb 2008Location: englandIP: 78.86.--.--
Posted:
by any chance could you please tell me how to call the new co-ordinates of the moved object using the ondragend function? I am new to javascript and don't have a clue where to start :(
Thanks, Graham.
4) graham01Group: Members Posts: 8Joined: 21 Feb 2008Location: englandIP: 78.86.--.--
Posted:
thanks for the help anyway, i have this sorted now :)