<!--
function newwindow()
{
	msgWindow = open(action +'?process=addr_only&cmd=msg_new&utoken=' + putoken + '&&','ADDRESSBOOK','width=600,height=250,toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=no,scrollbars=yes','POPUP');
	if (msgWindow.opener == null) msgWindow.opener = self;
        if (msgWindow.opener.sendform == null) msgWindow.opener.sendform = document.sendform;
	msgWindow.focus();
}

function dele(){
  var i = 0, j;
  
   for (j=0; j<4; j++)
     if (document.sendform.oo[j].checked == true) i = j;  

  if (i==0)
       document.sendform.to.value = "";
  if (i==1)
       document.sendform.cc.value = "";
  if (i==2)
       document.sendform.bcc.value = "";
  if (i==3)
       document.sendform.reply.value = "";
  document.sendform.tolist.options[0].selected = true;
}
function setto(sel) {
  var option;
  var i;
 
 for (i=0; i<sel.options.length; i++) {
   if (sel.options[i].selected==true) {
     if (document.sendform.oo[0].checked == true){
       if (document.sendform.to.value != "")
        document.sendform.to.value = ", " + document.sendform.to.value;
       document.sendform.to.value = sel.options[i].value + document.sendform.to.value;
     }
     if (document.sendform.oo[1].checked == true){
       if (document.sendform.cc.value != "")
        document.sendform.cc.value = ", " + document.sendform.cc.value;
       document.sendform.cc.value = sel.options[i].value + document.sendform.cc.value;
     }
     if (document.sendform.oo[2].checked == true){
       if (document.sendform.bcc.value != "")
        document.sendform.bcc.value = ", " + document.sendform.bcc.value;
       document.sendform.bcc.value = sel.options[i].value + document.sendform.bcc.value;
     }
     if (document.sendform.oo[3].checked == true){
       if (document.sendform.reply.value != "")
        document.sendform.reply.value = ", " + document.sendform.reply.value;
       document.sendform.reply.value = sel.options[i].value + document.sendform.reply.value;
     }
   }
 }
   if (sel.options[0].selected==true){
     dele();
   }
}
//-->
