home *** CD-ROM | disk | FTP | other *** search
/ Cricao de Sites - 650 Layouts Prontos / WebMasters.iso / Servidores / JanaSetup.exe / admin / pruefen_js / user_rights.js < prev    next >
Encoding:
Text File  |  2006-07-25  |  1.8 KB  |  129 lines

  1. function leeren()
  2. {
  3.     with (document.formular)
  4.     {
  5.         edit.value = '';
  6.         Item.value = '';
  7.     }
  8.  
  9.     feld_disabled();
  10. }
  11.  
  12. /**/
  13.  
  14. function feld_disabled()
  15. {
  16.     with (document.formular)
  17.     {
  18.         if (C1.checked)
  19.         {
  20.             T1.disabled = false;
  21.             C2.disabled = false;
  22.             D1.disabled = false;
  23.         }
  24.         else
  25.         {
  26.             T1.disabled = true;
  27.             C2.disabled = true;
  28.             D1.disabled = true;
  29.         }
  30.     }
  31. }
  32.  
  33. /**/
  34.  
  35. function Abfrage(edi, ite)
  36. {
  37.     var Check = confirm(txt[20][31]);
  38.  
  39.     with (document.formular)
  40.     {
  41.         if (Check && pruefen())
  42.         {
  43.             T1.disabled = (C1.checked || (T1.value == '')) ? false : true;
  44.             C2.disabled = false;
  45.             D1.disabled = false;
  46.  
  47.             edit.value = edi;
  48.             Item.value = ite;
  49.  
  50.             submit();
  51.         }
  52.         else
  53.         {
  54.             edit.value = '';
  55.             Item.value = '';
  56.         }
  57.     }
  58. }
  59.  
  60. /**/
  61.  
  62. function edit(edi, ite)
  63. {
  64.     if (pruefen())
  65.     {
  66.         with (document.formular)
  67.         {
  68.             T1.disabled = (C1.checked || (T1.value == '')) ? false : true;
  69.             C2.disabled = false;
  70.             D1.disabled = false;
  71.  
  72.             edit.value = edi;
  73.             Item.value = ite;
  74.  
  75.             submit();
  76.         }
  77.     }
  78. }
  79.  
  80. /**/
  81.  
  82. function send()
  83. {
  84.     if (pruefen())
  85.     {
  86.         with (document.formular)
  87.         {
  88.             T1.disabled = (C1.checked || (T1.value == '')) ? false : true;
  89.             C2.disabled = false;
  90.             D1.disabled = false;
  91.  
  92.             submit();
  93.         }
  94.     }
  95. }
  96.  
  97. /**/
  98.  
  99. function pruefen()
  100. {
  101.     with (document.formular)
  102.     {
  103.         if (C1.checked)
  104.         {
  105.             var f1 = T1.value;
  106.  
  107.             if ((f1 == '') || isNaN(f1) || (f1 < 0) || (f1 > 86400))
  108.             {
  109.                 alert(txt[19][9] + txt[26][8]);
  110.                 edit.value = '';
  111.                 Item.value = '';
  112.                 T1.select();
  113.                 T1.focus();
  114.                 return false;
  115.             }
  116.  
  117.             if ((D1.options[0].selected == false) && (D1.options[1].selected == false) && (D1.options[2].selected == false))
  118.             {
  119.                 alert(txt[26][13]);
  120.                 edit.value = '';
  121.                 Item.value = '';
  122.                 D1.focus();
  123.                 return false;
  124.             }
  125.         }
  126.     }
  127.  
  128.     return true;
  129. }