home *** CD-ROM | disk | FTP | other *** search
/ Cricao de Sites - 650 Layouts Prontos / WebMasters.iso / Servidores / JanaSetup.exe / admin / pruefen_js / allgemeine_server_parameter.js next >
Encoding:
Text File  |  2006-08-22  |  459 b   |  34 lines

  1. function send()
  2. {
  3.     if (pruefen())
  4.         document.formular.submit();
  5. }
  6.  
  7. /**/
  8.  
  9. function pruefen()
  10. {
  11.     with (document.formular)
  12.     {
  13.         var f1 = T1.value;
  14.         var f2 = T2.value;
  15.  
  16.         if (isNaN(f1) || (f1 < 1) || (f1 > 30))
  17.         {
  18.             alert(txt[17][4]);
  19.             T1.select();
  20.             T1.focus();
  21.             return false;
  22.         }
  23.  
  24.         if (isNaN(f2) || (f2 < 4) || (f2 > 20))
  25.         {
  26.             alert(txt[17][8]);
  27.             T2.select();
  28.             T2.focus();
  29.             return false;
  30.         }
  31.     }
  32.  
  33.     return true;
  34. }