home *** CD-ROM | disk | FTP | other *** search
/ Cricao de Sites - 650 Layouts Prontos / WebMasters.iso / Servidores / JanaSetup.exe / admin / pruefen_js / newsuser_edit.js < prev    next >
Encoding:
Text File  |  2006-05-08  |  1.0 KB  |  57 lines

  1. function pwfeld()
  2. {
  3.     if (document.formular.T1.value != '')
  4.         document.formular.T2.value = parent.header.document.dummy.feld.value;
  5. }
  6.  
  7. /**/
  8.  
  9. function send()
  10. {
  11.     if (pruefen() == true)
  12.         document.formular.submit();
  13. }
  14.  
  15. /**/
  16.  
  17. function pruefen()
  18. {
  19.     var f1 = document.formular.T1.value;
  20.     var f2 = document.formular.T2.value;
  21.     var fe = new Array('T1', 'T2');
  22.     var va = new Array('\'', '"', ',');
  23.  
  24.     for (i = 0; i < fe.length; i++)
  25.     {
  26.         for (j = 0; j < va.length; j++)
  27.         {
  28.             var ei = document.formular.elements[fe[i]];
  29.  
  30.             if (ei.value.indexOf(va[j]) != -1)
  31.             {
  32.                 alert(txt[5][7] + va[j] + txt[5][8]);
  33.                 ei.select();
  34.                 ei.focus();
  35.                 return false;
  36.             }
  37.         }
  38.     }
  39.  
  40.     if (f1.length < 4)
  41.     {
  42.         alert(txt[19][9] + txt[36][0] + txt[33][6]);
  43.         document.formular.T1.select();
  44.         document.formular.T1.focus();
  45.         return false;
  46.     }
  47.  
  48.     if (f2.length < 4)
  49.     {
  50.         alert(txt[19][9] + txt[27][2] + txt[27][21]);
  51.         document.formular.T2.select();
  52.         document.formular.T2.focus();
  53.         return false;
  54.     }
  55.  
  56.     return true;
  57. }