[jQuery validation]: unable to submit form: 1 required input type field and multiple hidden input type fields.

[jQuery validation]: unable to submit form: 1 required input type field and multiple hidden input type fields.

Hi,

I'm attempting to validate one form 'input type' field using jquery, but in this form are multiple other hidden 'input type' fields that need to be submitted with the validated field.

My problem is that my submit button isn't submitting, but the validation is working on the single field. It seems that it's trying to validate the hidden fields, and maybe my submit method is incorrect.

I've tried using ignore: ":hidden" inside the rules: { }, but it doesn't seem to do the trick.

This is my code:

  1. <script language="javascript" type="text/javascript">
  2. jQuery.validator.setDefaults({
  3. debug: true,
  4. success: "valid"
  5. });;
  6. </script>

  7.   <script>
  8.   $(document).ready(function(){
  9.     $("#form1").validate({
  10.   rules: {
  11.     points: {
  12.       required: true,
  13.       digits: true,
  14.  range: [1, 100],
  15.     }
  16.   }
  17. });
  18.   });
  19.   </script>
  20. </head>
  21. <body>
  22. <table width="500" border="0" cellspacing="0" cellpadding="0">
  23.   <tr>
  24.     <th scope="col">
  25. <form id="form1" name="form1" method="post" action="<?php echo $editFormAction; ?>">
  26.   <input type="text" name="points" id="points" />
  27.   <input type="hidden" name="Date" id="Date" value="now()" />
  28.     <input type="hidden" name="Description" id="Description" value="Point Value" />
  29.   <input type="hidden" name="AccountId" id="AccountId" value="<?php echo $row_rsCustomer['AccountId']; ?>" />
  30.   <input type="hidden" name="InsertDB" value="form1" />
  31.   <input type="hidden" name="UpdateDB" value="form1" />
  32.   <input type="image" src="images/enterkeybtn.png" name="submit" value="submit" />
  33. </form>
  34. </th>
  35.   </tr>
  36. </table>
Any insight would be greatly appreciated!
Thanks