Jquery sortable quesation

Jquery sortable quesation

Hi;

I use  this code to simply sort the lists. I need to also store the new order of sorted "ul li"s.

I thought when I re arrange, I also update a list so I can use 'foreach' with php and store the new order into the database? How can I do that? Any ideas?

Thank you