title: jquery form wizard validation
body: <p>I'm trying to implement a validation script (bassistance) with a jquery form wizard (<a href="http://www.jankoatwarpspeed.com/post/2009/09/28/webform-wizard-jquery.aspx" rel="nofollow noreferrer">http://www.jankoatwarpspeed.com/post/2009/09/28/webform-wizard-jquery.aspx</a>) but I'm having some problems.</p>
  
  <p>On the page for the jquery wizard, a guy named "Tommy" came up with a piece of code to implement bassistance with the code. But for some reason I can't get it to work. It comes up saying if the field needs to be filled in etc and the next button doesn't work - which is fine, BUT, if I fill in all the fields, the next button still doesn't work..</p>
  
  <pre><code>function createNextButton(i) {
  
              var stepName = "step" + i;
              $("#" + stepName + "commands").append("&lt;a href='#' id='" + stepName + "Next' class='next'&gt;Next &gt;&lt;/a&gt;");
  
              /* VALIDATION */
              if (options.validationEnabled) {
                  var stepIsValid = true; 
                  $("#" + stepName + " :input").each(function(index) { 
                      stepIsValid = !element.validate().element($(this)) &amp;&amp; stepIsValid;
                  });
                  if (!stepIsValid) {
                      return false; 
                  }
              }
              /* END VALIDATION */
  
              $("#" + stepName + "Next").bind("click", function(e) {
                  $("#" + stepName).hide();
                  $("#step" + (i + 1)).show();
                  if (i + 2 == count)
                      $(submmitButtonName).show();
                  selectStep(i + 1);
              });
  
          }
  </code></pre>
  
  <p>Could someone help me figure this one out? :)</p>