source: trunk/expressoAdmin1_2/js/jscode/users.js @ 414

Revision 414, 20.8 KB checked in by niltonneto, 16 years ago (diff)

Alterações feitas por João Alfredo.
Email: jakjr@…

  • Property svn:eol-style set to native
  • Property svn:executable set to *
Line 
1countFiles = 1;
2function validate_fields(type)
3{
4        if (type == 'create_user')
5        {
6                //UID
7                document.forms[0].uid.value = document.forms[0].uid.value.toLowerCase();
8               
9                if (document.forms[0].uid.value == ''){
10                        alert(get_lang('LOGIN field is empty') + '.');
11                        return;
12                }
13                else if (document.forms[0].uid.value.length < document.forms[0].minimumSizeLogin.value){
14                        alert(get_lang('LOGIN field must be bigger than') + ' ' + document.forms[0].minimumSizeLogin.value + ' ' + get_lang('characters') + '.');
15                        return;
16                }
17               
18                // Verifica se o delimitador do Cyrus permite ponto (dot.) nas mailboxes;
19                if (document.forms[0].imapDelimiter.value == '/')
20                        var reUid = /^([a-zA-Z0-9_\.\-])+$/;
21                else
22                        var reUid = /^([a-zA-Z0-9_\-])+$/;
23                if(!reUid.test(document.forms[0].uid.value)){
24                        alert(get_lang('LOGIN field contains characters not allowed') + '.');
25                        return;
26                }
27       
28                //PASSWORD's
29                if (document.forms[0].password1.value == ''){
30                        alert(get_lang('Password field is empty') + '.');
31                        return;
32                }
33                if (document.forms[0].password2.value == ''){
34                        alert(get_lang('Re-Password field is empty') + '.');
35                        return;
36                }
37        }
38
39        if (document.forms[0].password1.value != document.forms[0].password2.value){
40                alert(get_lang('Password and Re-Password are different') + '.');
41                return;
42        }
43       
44        // Corporative Information
45        if (document.forms[0].corporative_information_employeenumber.value != "")
46        {
47                var re_employeenumber = /^([0-9])+$/;
48               
49                if(!re_employeenumber.test(document.forms[0].corporative_information_employeenumber.value))
50                {
51                        alert(get_lang('EmployeeNumber contains characters not allowed') + '. ' + get_lang('Only numbers are allowed') + '.');
52                        document.forms[0].corporative_information_employeenumber.focus();
53                        return;
54                }
55        }
56
57        //MAIL
58        document.forms[0].mail.value = document.forms[0].mail.value.toLowerCase();
59        if (document.forms[0].mail.value == ''){
60                alert(get_lang('Email field is empty') + '.');
61                return;
62        }
63        var reEmail = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
64        if(!reEmail.test(document.forms[0].mail.value)){
65                alert(get_lang('Email field is not valid') + '.');
66                return false;
67        }
68       
69        //FIRSTNAME
70        var reGivenname = /^[a-zA-Z0-9 \-\.]+$/;
71        if(!reGivenname.test(document.forms[0].givenname.value)){
72                alert(get_lang('First name field contains characters not allowed') + '.');
73                return false;
74        }
75        else if (document.forms[0].givenname.value == ''){
76                alert(get_lang('First name field is empty') + '.');
77                return;
78        }
79       
80        //LASTNAME
81        var reSn = /^[a-zA-Z0-9 \-\.]+$/;
82        if(!reSn.test(document.forms[0].sn.value)){
83                alert(get_lang('Last name field contains characters not allowed') + '.');
84                return false;
85        }
86        else if (document.forms[0].sn.value == ''){
87                alert(get_lang('Last name field is empty') + '.');
88                return;
89        }
90       
91        //TELEPHONENUMBER
92        if (document.forms[0].telephonenumber.value != '')
93        {
94                reg_tel = /\(\d{2}\)\d{4}-\d{4}$/;
95                if (!reg_tel.exec(document.forms[0].telephonenumber.value))
96                {
97                        alert(get_lang('Phone field is incorrect') + '.');
98                        return;
99                }
100        }
101       
102        //FORWAR ONLY
103        if ((document.forms[0].deliverymode.checked) && (document.forms[0].mailforwardingaddress.value == '')){
104                alert(get_lang('Forward email is empty') + '.');
105                return;
106        }
107       
108        // Email Quota
109        if (document.forms[0].mailquota.value == ''){
110                alert(get_lang('User without email quota') + '.');
111                return;
112        }
113       
114        //GROUPS
115        if (document.getElementById('ea_select_user_groups').length < 1){
116                alert(get_lang('User is not in any group') + '.');
117                return;
118        }
119
120        //SAMBA
121        if (document.getElementById('tabcontent6').style.display != 'none'){
122                if ((document.forms[0].sambalogonscript.value == '') && (!document.forms[0].sambalogonscript.disabled)){
123                        alert(get_lang('Logon script is empty') + '.');
124                        return;
125                }
126                if ((document.forms[0].sambahomedirectory.value == '') && (!document.forms[0].sambahomedirectory.disabled)){
127                        alert(get_lang('Users home directory is empty') + '.');
128                        return;
129                }
130        }
131
132        // Uid, Mail and CPF exist?
133        var attrs_array = new Array();
134        attrs_array['type'] = type;
135        attrs_array['uid'] = document.forms[0].uid.value;
136        attrs_array['mail'] = document.forms[0].mail.value;
137        attrs_array['cpf'] = document.forms[0].corporative_information_cpf.value;
138       
139        if (document.forms[0].mailalternateaddress.value != '')
140                attrs_array['mailalternateaddress'] = document.forms[0].mailalternateaddress.value;
141        var attributes = connector.serialize(attrs_array);
142
143        var handler_validate_fields = function(data)
144        {
145                if (!data.status)
146                        alert(data.msg);
147                else
148                {
149                        if ( (data.question) && (!confirm(data.question)) )
150                        {
151                                return false;
152                        }
153
154                        if (type == 'create_user')
155                        {
156                                cExecuteForm ("$this.user.create", document.forms[0], handler_create);
157                        }
158                        else
159                        {
160                                //Turn enabled all checkboxes and inputs
161                                document.getElementById('changepassword').disabled = false;
162                                document.getElementById('phpgwaccountstatus').disabled = false;
163                                document.getElementById('phpgwaccountvisible').disabled = false;
164                                document.getElementById('telephonenumber').disabled = false;
165                                document.getElementById('mailforwardingaddress').disabled = false;
166                                document.getElementById('mailalternateaddress').disabled = false;
167                                document.getElementById('passwd_expired').disabled = false;
168                                document.getElementById('accountstatus').disabled = false;
169                                document.getElementById('deliverymode').disabled = false;
170                                document.getElementById('use_attrs_samba').disabled = false;
171                               
172                                table_apps = document.getElementById('ea_table_apps');
173                                var inputs = table_apps.getElementsByTagName("input");
174                                for (var i = 0; i < inputs.length; i++)
175                                {
176                                        inputs[i].disabled = false;
177                                }
178                                cExecuteForm ("$this.user.save", document.forms[0], handler_save);
179                        }
180                }
181        }
182       
183        // Needed select all options from select
184        select_user_maillists = document.getElementById('ea_select_user_maillists');
185        select_user_groups = document.getElementById('ea_select_user_groups');
186        for(var i=0; i<select_user_maillists.options.length; i++)
187                select_user_maillists.options[i].selected = true;
188        for(var i=0; i<select_user_groups.options.length; i++)
189                select_user_groups.options[i].selected = true;
190        /////////////////////////////////////////////////////////////////////////////////////////////////////////
191       
192        cExecute ('$this.ldap_functions.validate_fields&attributes='+attributes, handler_validate_fields);
193}
194
195// HANDLER CREATE
196// É necessário 2 funcões de retorno por causa do cExecuteForm.
197function handler_create(data)
198{
199        return_handler_create(data);
200}
201function return_handler_create(data)
202{
203        if (!data.status)
204                alert(data.msg);
205        else
206                alert(get_lang('User sucess created') + '.');
207
208        location.href="./index.php?menuaction=expressoAdmin1_2.uiaccounts.list_users";
209        return;
210}
211
212
213// HANDLER SAVE
214// É necessário 2 funcões de retorno por causa do cExecuteForm.
215function handler_save(data)
216{
217        return_handler_save(data);
218}
219function return_handler_save(data)
220{
221        if (!data.status){
222                alert(data.msg);
223        }
224        else{
225                alert(get_lang('User sucess saved') + '.');
226        }
227        location.href="./index.php?menuaction=expressoAdmin1_2.uiaccounts.list_users";
228        return;
229}
230
231function get_available_groups(context)
232{
233        var handler_get_available_groups = function(data)
234        {
235                select_available_groups = document.getElementById('ea_select_available_groups');
236
237                if ((data) && (data.length > 0))
238                {
239                        // Necessario, pois o IE6 tem um bug que retira o primeiro options se o innerHTML estiver vazio.
240                        select_available_groups.innerHTML = '#' + data;
241                        select_available_groups.outerHTML = select_available_groups.outerHTML;
242                        select_available_groups_clone = select_available_groups.cloneNode(true);
243                        document.getElementById('ea_input_searchGroup').value = '';
244                }
245                else
246                {
247                        // Necessario, pois o IE6 tem um bug que retira o primeiro options se o innerHTML estiver vazio.
248                        select_available_groups.innerHTML = '#';
249                        select_available_groups.outerHTML = select_available_groups.outerHTML;
250                }
251        }       
252               
253        cExecute ('$this.ldap_functions.get_available_groups&context='+context, handler_get_available_groups);
254}
255       
256function add_user2group()
257{
258        select_available_groups = document.getElementById('ea_select_available_groups');
259        select_user_groups = document.getElementById('ea_select_user_groups');
260        combo_primary_user_group = document.getElementById('ea_combo_primary_user_group');
261
262        for (i = 0 ; i < select_available_groups.length ; i++)
263        {
264                if (select_available_groups.options[i].selected)
265                {
266                        isSelected = false;
267                        for(var j = 0;j < select_user_groups.options.length; j++)
268                        {
269                                if(select_user_groups.options[j].value == select_available_groups.options[i].value)
270                                {
271                                        isSelected = true;                                             
272                                        break; 
273                                }
274                        }
275
276                        if(!isSelected)
277                        {
278                                new_option1 = document.createElement('option');
279                                new_option1.value =select_available_groups.options[i].value;
280                                new_option1.text = select_available_groups.options[i].text;
281                                new_option1.selected = true;
282                                select_user_groups.options[select_user_groups.options.length] = new_option1;
283                               
284                                new_option2 = document.createElement('option');
285                                new_option2.value =select_available_groups.options[i].value;
286                                new_option2.text = select_available_groups.options[i].text;
287                                combo_primary_user_group.options[combo_primary_user_group.options.length] = new_option2;
288                        }
289                }
290        }
291               
292        for (j =0; j < select_available_groups.options.length; j++)
293                select_available_groups.options[j].selected = false;
294}       
295       
296function remove_user2group()
297{
298        select_user_groups = document.getElementById('ea_select_user_groups');
299        combo_primary_user_group = document.getElementById('ea_combo_primary_user_group');
300       
301        var x;
302        var j=0;
303        var to_remove = new Array();
304       
305        for(var i = 0;i < select_user_groups.options.length; i++)
306        {
307                if(select_user_groups.options[i].selected)
308                {
309                        to_remove[j] = select_user_groups.options[i].value;
310                        j++;
311                        select_user_groups.options[i--] = null;
312                }
313        }
314       
315        for (x in to_remove)
316        {
317                for(var i=0; i<combo_primary_user_group.options.length; i++)
318                {
319                        if (combo_primary_user_group.options[i].value == to_remove[x])
320                        {
321                                combo_primary_user_group.options[i] = null;
322                        }       
323                }
324        }
325}
326       
327function get_available_maillists(context)
328{
329        var handler_get_available_maillists = function(data)
330        {
331                select_available_maillists = document.getElementById('ea_select_available_maillists');
332
333                if ((data) && (data.length > 0))
334                {
335                        // Necessario, pois o IE6 tem um bug que retira o primeiro options se o innerHTML estiver vazio.
336                        select_available_maillists.innerHTML = '#' + data;
337                        select_available_maillists.outerHTML = select_available_maillists.outerHTML;
338                        select_available_maillists_clone = select_available_maillists.cloneNode(true);
339                        document.getElementById('ea_input_searchMailList').value = '';
340                }
341                else
342                {
343                        // Necessario, pois o IE6 tem um bug que retira o primeiro options se o innerHTML estiver vazio.
344                        select_available_maillists.innerHTML = '#';
345                        select_available_maillists.outerHTML = select_available_maillists.outerHTML;
346                }
347        }
348        cExecute ('$this.ldap_functions.get_available_maillists&context='+context, handler_get_available_maillists);
349}
350       
351function add_user2maillist()
352{
353        select_available_maillists = document.getElementById('ea_select_available_maillists');
354        select_user_maillists = document.getElementById('ea_select_user_maillists');
355
356        for (i = 0 ; i < select_available_maillists.length ; i++)
357        {
358
359                if (select_available_maillists.options[i].selected)
360                {
361                        isSelected = false;
362                        for(var j = 0;j < select_user_maillists.options.length; j++)
363                        {
364                                if(select_user_maillists.options[j].value == select_available_maillists.options[i].value)
365                                {
366                                        isSelected = true;                                             
367                                        break; 
368                                }
369                        }
370
371                        if(!isSelected)
372                        {
373                                new_option = document.createElement('option');
374                                new_option.value =select_available_maillists.options[i].value;
375                                new_option.text = select_available_maillists.options[i].text;
376                                new_option.selected = true;
377                                       
378                                select_user_maillists.options[select_user_maillists.options.length] = new_option;
379                        }
380                }
381        }
382               
383        for (j =0; j < select_available_maillists.options.length; j++)
384                select_available_maillists.options[j].selected = false;
385}       
386       
387function remove_user2maillist()
388{
389        select_user_maillists = document.getElementById('ea_select_user_maillists');
390
391        for(var i = 0;i < select_user_maillists.options.length; i++)
392                if(select_user_maillists.options[i].selected)
393                        select_user_maillists.options[i--] = null;
394}
395       
396function sinc_combos_org(context)
397{
398        combo_org_groups = document.getElementById('ea_combo_org_groups');
399        combo_org_maillists = document.getElementById('ea_combo_org_maillists');
400
401        for (i=0; i<combo_org_groups.length; i++)
402        {
403                if (combo_org_groups.options[i].value == context)
404                {
405                        combo_org_groups.options[i].selected = true;
406                        combo_org_maillists.options[i].selected = true;
407                }
408        }
409}
410       
411function use_samba_attrs(value)
412{
413        if (value)
414        {
415                if (document.forms[0].sambalogonscript.value == '')
416                {
417                        if (document.forms[0].defaultLogonScript.value == '')
418                        {
419                                document.forms[0].sambalogonscript.value = document.forms[0].uid.value + '.bat';
420                        }
421                        else
422                        {
423                                document.forms[0].sambalogonscript.value = document.forms[0].defaultLogonScript.value;
424                        }
425                }
426                if (document.forms[0].sambahomedirectory.value == '')
427                {
428                        document.forms[0].sambahomedirectory.value = '/home/'+document.forms[0].uid.value+'/';
429                }
430        }
431       
432        if (!document.forms[0].use_attrs_samba.disabled)
433        {
434                document.forms[0].sambaacctflags.disabled = !value;
435                document.forms[0].sambadomain.disabled = !value;
436                document.forms[0].sambalogonscript.disabled = !value;
437                document.forms[0].sambahomedirectory.disabled = !value;
438        }
439}
440       
441function set_user_default_password()
442{
443        var handler_set_user_default_password = function(data)
444        {
445                if (!data.status)
446                        alert(data.msg);
447                else
448                        alert(get_lang('Default password sucess saved') + '.');
449                return;
450        }
451        cExecute ('$this.user.set_user_default_password&uid='+document.forms[0].uid.value, handler_set_user_default_password); 
452}
453
454function return_user_password()
455{
456        var handler_return_user_password = function(data)
457        {
458                if (!data.status)
459                        alert(data.msg);
460                else
461                        alert(get_lang('Users password sucess returned') + '.');
462                return;
463        }
464        cExecute ('$this.user.return_user_password&uid='+document.forms[0].uid.value, handler_return_user_password);
465}
466
467function delete_user(uid, uidnumber)
468{
469        if (confirm(get_lang("Do you really want delete the user") + " " + uid + "?"))
470        {
471                var handler_delete_user = function(data)
472                {
473                        if (!data.status)
474                                alert(data.msg);
475                        else
476                                alert(get_lang('User sucess deleted') + '.');
477                       
478                        location.href="./index.php?menuaction=expressoAdmin1_2.uiaccounts.list_users";
479                        return;
480                }
481                cExecute ('$this.user.delete&uidnumber='+uidnumber, handler_delete_user);
482        }
483}
484
485function rename_user(uid, uidnumber)
486{
487        if (document.getElementById('accounts_form_imapDelimiter').value == '/')
488                var reUid = /^([a-zA-Z0-9_\.\-])+$/;
489        else
490                var reUid = /^([a-zA-Z0-9_\-])+$/;
491
492        new_uid = prompt(get_lang('Rename users login from') + ': ' + uid + " " + get_lang("to") + ': ', uid);
493
494        if(!reUid.test(new_uid)){
495                alert(get_lang('LOGIN field contains characters not allowed') + '.');
496                document.forms[0].account_lid.focus();
497                return;
498        }
499       
500        if ((new_uid) && (new_uid != uid))
501        {
502                var handler_validate_fields = function(data)
503                {
504                        if (!data.status)
505                                alert(data.msg);
506                        else
507                                cExecute ('$this.user.rename&uid='+uid+'&new_uid='+new_uid, handler_rename);
508                       
509                        return;
510                }
511               
512                // New uid exist?
513                attrs_array = new Array();
514                attrs_array['type'] = 'rename_user';
515                attrs_array['uid'] = new_uid;
516                attributes = connector.serialize(attrs_array);
517       
518                cExecute ('$this.ldap_functions.validate_fields&attributes='+attributes, handler_validate_fields);
519        }
520}
521
522// HANDLER RENAME
523function handler_rename(data)
524{
525        if (!data.status)
526                alert(data.msg);
527        else{
528                alert(get_lang('User login sucess renamed') + "\n" + data.exec_return);
529                location.href="./index.php?menuaction=expressoAdmin1_2.uiaccounts.list_users";
530        }
531        return;
532
533}
534
535
536// Variaveis Locais
537var finderTimeout_maillist = '';
538
539// Funcoes Find MailList
540function optionFinderTimeout_maillist(obj)
541{
542        clearTimeout(finderTimeout_maillist);
543        var oWait = document.getElementById("ea_span_searching_maillist");
544        oWait.innerHTML = get_lang('Searching') + '...';
545        finderTimeout_maillist = setTimeout("optionFinder_maillist('"+obj.id+"')",500);
546}
547function optionFinder_maillist(id) {
548        var oWait = document.getElementById("ea_span_searching_maillist");
549        var oText = document.getElementById(id);
550               
551        //Limpa todo o select
552        for(var i = 0;i < select_available_maillists.options.length; i++)
553                select_available_maillists.options[i--] = null;
554       
555        var RegExp_name = new RegExp(oText.value, "i");
556       
557        //Inclui as listas começando com a pesquisa
558        for(i = 0; i < select_available_maillists_clone.length; i++){
559                if (RegExp_name.test(select_available_maillists_clone[i].text))
560                {
561                        sel = select_available_maillists.options;
562                        option = new Option(select_available_maillists_clone[i].text,select_available_maillists_clone[i].value);                               
563                        sel[sel.length] = option;
564                }
565        }
566        oWait.innerHTML = '&nbsp;';
567}                       
568
569// Variaveis Locais
570var finderTimeout_group = '';
571
572
573// Funcoes Find Group
574function optionFinderTimeout_group(obj)
575{
576        clearTimeout(finderTimeout_group);
577        var oWait = document.getElementById("ea_span_searching_group");
578        oWait.innerHTML = get_lang('Searching') + '...';
579        finderTimeout_group = setTimeout("optionFinder_group('"+obj.id+"')",500);
580}
581function optionFinder_group(id) {       
582        var oWait = document.getElementById("ea_span_searching_group");
583        var oText = document.getElementById(id);
584               
585        //Limpa todo o select
586        for(var i = 0;i < select_available_groups.options.length; i++)
587                select_available_groups.options[i--] = null;
588       
589        var RegExp_name = new RegExp(oText.value, "i");
590       
591        //Inclui as listas começando com a pesquisa
592        for(i = 0; i < select_available_groups_clone.length; i++){
593                if (RegExp_name.test(select_available_groups_clone[i].text))
594                {
595                        sel = select_available_groups.options;
596                        option = new Option(select_available_groups_clone[i].text,select_available_groups_clone[i].value);                             
597                        sel[sel.length] = option;
598                }
599        }
600        oWait.innerHTML = '&nbsp;';
601}
602
603function get_available_sambadomains(context, type)
604{
605        if ((type == 'create_user') && (document.getElementById('tabcontent7').style.display != 'none'))
606        {
607                var handler_get_available_sambadomains = function(data)
608                {
609                        document.forms[0].use_attrs_samba.checked = data.status;
610                        use_samba_attrs(data.status);
611                       
612                        if (data.status)
613                        {
614                                combo_sambadomains = document.getElementById('ea_combo_sambadomains');
615                                for (i=0; i<data.sambaDomains.length; i++)
616                                {
617                                        for (j=0; j<combo_sambadomains.length; j++)
618                                        {
619                                                if (combo_sambadomains.options[j].text == data.sambaDomains[i])
620                                                {
621                                                        combo_sambadomains.options[j].selected = true;
622                                                        break;
623                                                }
624                                        }
625                                }
626                               
627                        }
628                }
629               
630                cExecute ('$this.ldap_functions.exist_sambadomains_in_context&context='+context, handler_get_available_sambadomains);
631        }
632}
633
634function empty_inbox(uid)
635{
636        var action = get_lang('Cleanned user mailbox');
637        var handler_write_log = function(){}
638        var handler_empty_inbox = function(data)
639        {
640                if (!data.status)
641                        alert(data.msg);
642                else{
643                        cExecute ('$this.user.write_log_from_ajax&_action='+action+'&userinfo='+uid, handler_write_log);
644                        alert(get_lang('Emptied ') + data.inbox_size + ' ' + get_lang('MB from user inbox'));
645                        document.getElementById('mailquota_used').value = data.mailquota_used;
646                }
647        }
648        cExecute ('$this.imap_functions.empty_inbox&uid='+uid, handler_empty_inbox);
649}
650
651function validarCPF(cpf)
652{
653        if(cpf.length != 11 || cpf == "00000000000" || cpf == "11111111111" ||
654                cpf == "22222222222" || cpf == "33333333333" || cpf == "44444444444" ||
655                cpf == "55555555555" || cpf == "66666666666" || cpf == "77777777777" ||
656                cpf == "88888888888" || cpf == "99999999999"){
657          return false;
658   }
659
660        soma = 0;
661        for(i = 0; i < 9; i++)
662                soma += parseInt(cpf.charAt(i)) * (10 - i);
663        resto = 11 - (soma % 11);
664        if(resto == 10 || resto == 11)
665                resto = 0;
666        if(resto != parseInt(cpf.charAt(9)))
667        {
668                return false;
669        }
670       
671        soma = 0;
672        for(i = 0; i < 10; i ++)
673                soma += parseInt(cpf.charAt(i)) * (11 - i);
674        resto = 11 - (soma % 11);
675        if(resto == 10 || resto == 11)
676                resto = 0;
677        if(resto != parseInt(cpf.charAt(10))){
678                return false;
679        }
680        return true;
681}
682
683function search_organization(key, element)
684{
685        var organizations = document.getElementById(element);
686        var RegExp_org = new RegExp("\\b"+key, "i");
687       
688        for(i = 0; i < organizations.length; i++)
689        {
690                if (RegExp_org.test(organizations[i].text))
691                {
692                        organizations[i].selected = true;
693                        return;
694                }
695        }
696}
697
698function add_input_mailalternateaddress()
699{
700        var input = document.createElement("INPUT");
701        input.size = 30;
702        input.name = "mailalternateaddress[]";
703        input.setAttribute("autocomplete","off");
704        document.getElementById("td_input_mailalternateaddress").appendChild(document.createElement("br"));
705        document.getElementById("td_input_mailalternateaddress").appendChild(input);
706}
707
708function add_input_mailforwardingaddress()
709{
710        var input = document.createElement("INPUT");
711        input.size = 30;
712        input.name = "mailforwardingaddress[]";
713        input.setAttribute("autocomplete","off");
714        document.getElementById("td_input_mailforwardingaddress").appendChild(document.createElement("br"));
715        document.getElementById("td_input_mailforwardingaddress").appendChild(input);
716}
Note: See TracBrowser for help on using the repository browser.