title: Jquery validating email using RegEx
body: <p>I'm trying to validate a email using the code below currently it tests the email to see if it matches the regex but even when a valid email is entered the error is activated and the page does not submit</p>
  
  <pre><code>    $('#emailsubmit').submit(function() {
      var email = new RegExp(/^(([^&lt;&gt;()[\]\\.,;:\s@\"]+(\.[^&lt;&gt;()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/);
  
  
      if (!("#emailAddr").match(email)) {
          $("#errormsg").html("Please insert a valid email");
          $("#errormsg").show();
  
           var emailaddr = $("#emailAddr").val();
  
          alert(emailaddr);
          return false;
      } 
  
  });
  </code></pre>