jQuery/Javascript custom email validation not working
<p>I didn't want to us a plugin for simple email validations so i tried to create my own but it doesn't work.  Its always returning false.  Here is my code:</p>

<pre><code>var regex = /\A[\w+\-.]+@[a-z\d\-.]+\.[a-z]+\z/i;

if(regex.test($("#email").val()))
{
    //pass
}
</code></pre>

<p>What am I doing wrong?  Thank you!</p>
