title: jQuery validation plugin error: TypeError: validator is undefined
body: <p>Here is html code for the form:</p>
  
  <pre><code>&lt;form method="post" id="login" action="/login"&gt;
   &lt;div class="login-element"&gt;
      &lt;label for="email"&gt;E-Mail&lt;/label&gt;
      &lt;input type="text" name="email"&gt;
  &lt;/div&gt;
  &lt;div class="login-element"&gt;
      &lt;label for="password"&gt;Passwort&lt;/label&gt;
      &lt;input type="password"  name="password"&gt;
  &lt;/div&gt;
  &lt;div class="login-element"&gt;
      &lt;input type="submit" value="Login"&gt;
  &lt;/div&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>and here is the code that I used for validation:</p>
  
  <pre><code>    $(document).ready(function() { 
      $("#login").validate({
         debug: true,
         rules: {
              email: {
                required: true,
                email: true
              },
              password: {
                required: true
              }
          },
          messages: {
              email: {
                  required: "Please enter a email adress",
                  email: "Please enter a valid email address"
              },
              password:"Please enter password"
          }
      });
      });
  </code></pre>
  
  <p>In the console following error is logged: </p>
  
  <pre><code>TypeError: validator is undefined
  ...or.settings[eventType] &amp;&amp; validator.settings[eventType].call(validator, this[0],...
  </code></pre>
  
  <p>What could be the issue here?</p>