Saving JQuery UI sortable arangement

Saving JQuery UI sortable arangement

Hi folks

I'd like to save the position of every single children in a sortable (portlets to be exact). I've a 3 row sortable and I'm able to sort everything within each of the rows and to share elements between them. My next step is to save the positions of the elements into my database so that when i reopen the page it'll restore my arrangement.

I've now tried for hours to read the id's, positions and so on but it seems, my ideas wont work properly.

And here's what I need: When a children is moved (and its position really changed) I need two values: The row (a div in this case) and the position inside this div. for the position it should be integer and for the div either integer or the div-id.

Can someone help me with that?