home *** CD-ROM | disk | FTP | other *** search
/ PC World 2005 February / PCWorld_2005-02_cd.bin / komunikace / slim / sbsetup.exe / SubmitForm.js < prev    next >
Text File  |  2003-06-18  |  240b  |  14 lines

  1. function SubmitForm(vForm)
  2. {
  3.     if (vForm==null) return false;
  4.     for(var i=0;i<vForm.elements.length;i++)    
  5.     {
  6.         var elem=vForm.elements[i];
  7.         if (elem.type=="submit") 
  8.         {
  9.             elem.click();
  10.             return true;
  11.         }
  12.     }
  13.     vForm.submit();
  14. }