copying options of select into another select

copying options of select into another select

I have 2 html-selects, one as source, the other as target. I want to copy the source-options to the target.
#sel_rel > source
#sel_new_after_rel > target
  1. function openFormAddRel(){
  2.     generateFieldset("Release hinzufügen", "reg_edit", "form_add_rel");
  3.     var root=$("#form_add_rel");
  4.     root.append("<input id='inp_rel_add_name'></input>");
  5.     root.append(" einordnen <select id='sel_new_after_rel'></select>");
  6.     $("#sel_new_after_rel").append("<option id='sel_new_after_rel_0' name='0'>als ersten</option>");
  7.     var sellist=$("#sel_rel").children();
  8.     var id;
  9.     var newitem;
  10.     $.each(sellist, function(i,item) {
  11.         if (i!=0) {
  12.             newitem=item;
  13.             $("#sel_new_after_rel").append(newitem);
  14.             id=$("#sel_new_after_rel").children(":last").attr("id");
  15.             newid=id.replace(/sel_rel_/g,"");
  16.             $("#sel_new_after_rel").children(":last").attr("id","sel_new_after_rel_"+newid);
  17.             $("#sel_new_after_rel_"+newid).prepend("nach ");
  18.         }
  19.     });
  20.     root.append("<button id='but_rel_add_name'>Hinzuf&uuml;gen</button>");
  21.     $("#but_rel_add_name").attr("onClick","relAddName()");
  22. }
While appending the option-elements to the targetselect the original option-elements disappear (exactly at step of line 13). This is unwanted behaviour. How can I prevent this?