Hi there. I've made some very weird "logic error" in the follow code, that I want to use in a CGI application later. Although It's JavaScript, I would properly make the same error in Perl aswell:

If you try out the code, you'll see something goes wrong now and then (see attachment). - Select some names in the first multiselect box. - Click add - Select some names in the second multiselect box - click remove. - When moving options from one to another select box, the JavaScript will keep the sorting/sequence of the elements identical. (causing the error) - Repeat that until you get that **** error.

Some combinations seam to result in a weird error. Can anyone explain me why that happens??