regex for email validation Not Working with Subdomains?
<p>I'm using the following for email validation:</p>

<pre><code>var filter = /^([\w]+)(.[\w]+)*@([\w]+)(.[\w]{2,3}){1,2}$/; // For Email Validation

if (filter.test(emailInputVal))) {console.log('good')}
</code></pre>

<p>For some reason the above does not work with emails that have a subdomain Any ideas why?</p>

<pre><code>xxxx@xxx.xxx.com 
</code></pre>

<p>Thanks</p>
