This is how i handle select lists...not totally sure of cross-browser, or browser versions (what works where), but everything seems to work in IE and Netscape that I've tested.
To find out which item(s) are selected, for example:
for (i = 0; i < document.frm.sel.length; i++)
if (document.frm.sel.item(i).selected)
//item is selected
But I'm a little confused of what you were asking for... I thought you already had the list ordered, dynamically, using javascript. So, anyway, here's what i know...if it helps any.
To remove an item from a list:
document.frm.sel.remove(i);
To add an item to a list:
var elt = document.createElement('option');
elt.value = 'val';
elt.text = 'text';
document.frm.sel.add(elt);
delete elt;
Form a csv string of all the items in a list:
var s = "";
for (i = 0; i < document.frm.sel.length; i++)
s += document.frm.sel.item(i).text + ",";